Tribhuvan University | Old Is Gold
Institute Of Science And Technology
Computer Science and Information Technology
Course: Fundamental Of Computer Programming
Level: Bachelor | First Year | Semester: First | Year 2070 | Science
Full Marks: 60 | Pass Marks: 24 | Time: 3 Hrs
| Download - File Size: 119 kb | Question Paper Of 'Fundamental Of Computer Programming' 2070 | CSIT | TU
Candidates are required to give their answers in their own words as for as practicable.
All questions carry equal marks.
Attempt all questions.
1. What is logical error? Write flowchart and program for checking whether the number entered by the user is exactly divisible by 5 or by 11. [1+5]
OR
What is algorithm? Write an algorithm to check given number is prime or composite. [1+5]
2. What is operator? List any six operators used in C-programming language. Write a program to find least number between any two numbers using ternary operator. [1+2+3]
3. Define printf() function, header file and main function. Find the value of following expression. Use the value initially assigned to the variables for each expressions. [4.5+1.5]
int a=8, b=5;
float x=0.005, y= -0.01;
1. 2*((a/5)+4*(b-3))%(a+b-2));
2. (x>y)&&(a>0)11(b<5);
3. (a>b)?a:b;
4. Difference between if and switch statement. Write a program to read the marks of four subjects then find total, percentage and division according to given condition. [1+5]
Attempt all questions.
1. What is logical error? Write flowchart and program for checking whether the number entered by the user is exactly divisible by 5 or by 11. [1+5]
OR
What is algorithm? Write an algorithm to check given number is prime or composite. [1+5]
2. What is operator? List any six operators used in C-programming language. Write a program to find least number between any two numbers using ternary operator. [1+2+3]
3. Define printf() function, header file and main function. Find the value of following expression. Use the value initially assigned to the variables for each expressions. [4.5+1.5]
int a=8, b=5;
float x=0.005, y= -0.01;
1. 2*((a/5)+4*(b-3))%(a+b-2));
2. (x>y)&&(a>0)11(b<5);
3. (a>b)?a:b;
4. Difference between if and switch statement. Write a program to read the marks of four subjects then find total, percentage and division according to given condition. [1+5]
Percentage
|
Division |
p ≥ 80
|
Distinction |
80 > p ≥ 70
|
First division |
70 > p ≥ 50
|
Second division |
50 > p ≥ 40
|
Third division |
Otherwise
|
Fail |
Assume each subjects carrying 100 full marks and students must secure greater or equal to 40 in each subjects for division.
5. Differentiate between break and continue statement. Write a program to display following output. [2+4]
1
1 1
1 1 1
1 1 1 1
1 1 1 1 1
6. Write a program to input any 10 numbers then find out greatest and smallest number. [6]
7. Write a program to add two 3×3 matrix using function. [6]
8. What is recursion? Write a program to find the factorial of given number using recursion. [2+4]
OR
What is pointer? Write a program to sort 'n' numbers in ascending order using dynamic memory. [2+4]
9. List any five names of graphics function. Write a program to read line of text then count no. of vowels. No. of digits and no. of spaces. [2+4]
10. Write a program to create a file "RECORD.TXT" then store roll no, name and percentage of 10 students. [6]
Thank you!!
ReplyDeleteYou are Welcome!!
DeletePost a Comment
We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow.
Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.