Exam Details
Subject | computer programming | |
Paper | ||
Exam / Course | b.tech | |
Department | ||
Organization | Institute Of Aeronautical Engineering | |
Position | ||
Exam Date | February, 2018 | |
City, State | telangana, hyderabad |
Question Paper
Hall Ticket No Question Paper Code: ACS001
INSTITUTE OF AERONAUTICAL ENGINEERING
(Autonomous)
B.Tech I Semester End Examinations (Supplementary) February, 2018
Regulation: IARE R16
COMPUTER PROGRAMMING
Common for (CSE IT ECE EEE)
Time: 3 Hours Max Marks: 70
Answer ONE Question from each Unit
All Questions Carry Equal Marks
All parts of the question must be answered in one place only
UNIT I
1. Write a C program to find the smallest of three numbers using conditional operator.
Differentiate the following operators giving suitable examples.
i. Bitwise left shift and right shift
ii. Post and pre increment
iii. Logical AND and Logical OR
iv. Unary and binary operator
2. Write an algorithm to find the sum of all integers between 100 and 500 that are not divisible by
10. Also draw the flow chart for the same. State which approach do you prefer to use and why?
i. Draw a flowchart to find the roots of a quadratic equation.
ii. Write a C program to find whether the given two numbers are equal or not?
UNIT II
3. With appropriate examples, explain the following string handling functions.
i. strncat
ii. strcmp
iii. strchr
iv. strstr
Write a C program to display the given string in an alphabetical order.
4. Differentiate break and continue statements in C. Illustrate with a program segment.
Write a C program to print twin prime numbers between 1 to 100. Examples for twin prime
numbers are difference of 2 between consecutive prime numbers.
UNIT III
5. How to pass one function as an argument to the another function. Write a C program to calculate
square and cube of a given number using function as an argument.
What is a generic pointer? Which operations are not permitted on pointers?
Page 1 of 2
6. Discuss the usage of the following preprocessor directives.
i. #define
ii. #ifdef
iii. #endif
Write a C program to find matrix multiplication using pointers.
UNIT IV
7. What are structures? How they are different from unions. Give example for each.
i. Construct an array of structure called "student" with the data members: name, roll-no, class,
grade and percentage marks. Read n records and print the details of the student given a
particular roll-no as the key
ii. Define a structure by name 'complex' consisting of real and imaginary parts of a complex
number. Write a C program to add two such complex numbers.
8. The annual examination is conducted for 10 students on three subjects. Write a C program to
read the data and find the total marks of each student.
i. Discuss the functions used in dynamic memory allocation with appropriate examples.
ii. Develop a C program to demonstrate passing structures as parameters to functions.
UNIT V
9. Write a C program to display the contents of a file in reverse order.
Write a C program to read name and marks of n number of students from user and store them
in a file. If the file previously exits, add the information of n students.
10. Write a C program to count number of characters, number of words and number of lines in a
given file.
Write a C program to find number of vowels in the given file use command line arguments.
INSTITUTE OF AERONAUTICAL ENGINEERING
(Autonomous)
B.Tech I Semester End Examinations (Supplementary) February, 2018
Regulation: IARE R16
COMPUTER PROGRAMMING
Common for (CSE IT ECE EEE)
Time: 3 Hours Max Marks: 70
Answer ONE Question from each Unit
All Questions Carry Equal Marks
All parts of the question must be answered in one place only
UNIT I
1. Write a C program to find the smallest of three numbers using conditional operator.
Differentiate the following operators giving suitable examples.
i. Bitwise left shift and right shift
ii. Post and pre increment
iii. Logical AND and Logical OR
iv. Unary and binary operator
2. Write an algorithm to find the sum of all integers between 100 and 500 that are not divisible by
10. Also draw the flow chart for the same. State which approach do you prefer to use and why?
i. Draw a flowchart to find the roots of a quadratic equation.
ii. Write a C program to find whether the given two numbers are equal or not?
UNIT II
3. With appropriate examples, explain the following string handling functions.
i. strncat
ii. strcmp
iii. strchr
iv. strstr
Write a C program to display the given string in an alphabetical order.
4. Differentiate break and continue statements in C. Illustrate with a program segment.
Write a C program to print twin prime numbers between 1 to 100. Examples for twin prime
numbers are difference of 2 between consecutive prime numbers.
UNIT III
5. How to pass one function as an argument to the another function. Write a C program to calculate
square and cube of a given number using function as an argument.
What is a generic pointer? Which operations are not permitted on pointers?
Page 1 of 2
6. Discuss the usage of the following preprocessor directives.
i. #define
ii. #ifdef
iii. #endif
Write a C program to find matrix multiplication using pointers.
UNIT IV
7. What are structures? How they are different from unions. Give example for each.
i. Construct an array of structure called "student" with the data members: name, roll-no, class,
grade and percentage marks. Read n records and print the details of the student given a
particular roll-no as the key
ii. Define a structure by name 'complex' consisting of real and imaginary parts of a complex
number. Write a C program to add two such complex numbers.
8. The annual examination is conducted for 10 students on three subjects. Write a C program to
read the data and find the total marks of each student.
i. Discuss the functions used in dynamic memory allocation with appropriate examples.
ii. Develop a C program to demonstrate passing structures as parameters to functions.
UNIT V
9. Write a C program to display the contents of a file in reverse order.
Write a C program to read name and marks of n number of students from user and store them
in a file. If the file previously exits, add the information of n students.
10. Write a C program to count number of characters, number of words and number of lines in a
given file.
Write a C program to find number of vowels in the given file use command line arguments.
Other Question Papers
Subjects
- ac machines
- advanced databases
- aircraft materials and production
- aircraft performance
- aircraft propulsion
- aircraft systems and controls
- analog communications
- analysis of aircraft production
- antennas and propagation
- applied physics
- applied thermodynamics
- basic electrical and electronics engineering
- basic electrical engineering
- building materials construction and planning
- business economics and financial analysis
- compiler design
- complex analysis and probability distribution
- computational mathematics and integral calculus
- computer networks
- computer organization
- computer organization and architecture
- computer programming
- concrete technology
- control systems
- data structures
- database management systems
- dc machines and transformers
- design and analysis of algorithms
- design of machine members
- digital and pulse circuits
- digital communications
- digital ic applications using vhdl
- digital logic design
- digital system design
- disaster management
- disaster management and mitigation
- discrete mathematical structures
- dynamics of machinery
- electrical circuits
- electrical measurements and instrumentation
- electrical technology
- electromagnetic field theory
- electromagnetic theory and transmission lines
- electronic circuit analysis
- electronic devices and circuits
- elements of mechanical engineering
- engineering chemistry
- engineering drawing
- engineering geology
- engineering mechanics
- engineering physics
- english
- english for communication
- environmental studies
- finite element methods
- fluid mechanics
- fluid mechanics and hydraulics
- fundamental of electrical and electronics engineering
- fundamental of electrical engineering
- gender sensitivity
- geotechnical engineering
- heat transfer
- high speed aerodynamics
- hydraulics and hydraulic machinery
- image processing
- industrial automation and control
- instrumentation and control systems
- integrated circuits applications
- introduction to aerospace engineering
- kinematics of machinery
- linear algebra and calculus
- linear algebra and ordinary differential equations
- low speed aerodynamics
- machine tools and metrology
- mathematical transform techniques
- mathematical transforms techniques
- mechanics of fluids and hydraulic machines
- mechanics of solids
- mechanism and machine design
- metallurgy and material science
- microprocessor and interfacing
- modern physics
- network analysis
- object oriented analysis and design
- object oriented programming through java
- operating systems
- optimization techniques
- power electronics
- power generation systems
- probability and statistics
- probability theory and stochastic processes
- production technology
- programming for problem solving
- pulse and digital circuits
- reinforced concrete structures design and drawing
- software engineering
- strength of materials - i
- strength of materials - ii
- structural analysis
- surveying
- theory of computation
- theory of structures
- thermal engineering
- thermo dynamics
- thermodynamics
- tool design
- transmission and distribution systems
- unconventional machining processes
- waves and optics
- web technologies