FOP Assignment U 1 To U 3
FOP Assignment U 1 To U 3
TECHNOLOGY
FOP Assignment
Subject code: CE3002
Unit 1
18. Find out any four syntax errors from the following code.
#include<iostream>
using namespace std;
int MAIN()
{
int radius=10, circle_area=0;
circle area =PI * radius * radius
cout<<"Area of Circle <<circle_area;
return 0;
}
19. Write any two differences between source code and object code.
20. What is constant? Explain in detail four basic types of constants available in C++ or
JAVA language. Also, write at least two differences between literal constant and
symbolic constant by giving an appropriate example.
21. What is an algorithm? Enlist and explain its characteristics.
22. Draw the following symbols used in the flowchart: Start/Stop/Terminal, Input,
Processing, Decision, Output, and Connector.
23. Draw a flowchart or write a pseudocode/Algorithm to represent the logic of a program
that allows the user to enter a value. The program multiplies the value by 10 and outputs
the result.
24. Draw a flowchart or write pseudocode to represent the logic of a program that allows
the user to enter a value for the radius of a circle. The program calculates the diameter
by multiplying the radius by 2 and then calculates the circumference by multiplying the
diameter by 3.14. The program outputs both the diameter and the circumference
25. Explain the structure of the C++ program.
26. Write the advantages and disadvantages of a flowchart. Explain the various symbols
used in flowcharts.
27. Explain the structure of the Java Program.
28. Draw the flowchart for the
1. To calculate the area of circle and triangle.
2. To find out the largest number out of three numbers.
3. To print first 50 even numbers.
4. To find the sum and percentage of given n numbers.
5. To check whether the given number is prime or not.
6. To find the factorial of the given number.
7. To accept n numbers from the user and count how many of them where odd
and also compute the sum of these odd numbers.
8. To convert the temperature from Fahrenheit to Celsius.
Unit 2