Using for loop c programmes

Great! Practicing for loops in C is an excellent way to strengthen your understanding of programming logic and structure. Here are 10 C programming exercises using for loops for practice, from beginner to intermediate level: --- ✅ 1. Print Numbers from 1 to N Goal: Input n and print numbers from 1 to n. int n; printf("Enter a number: "); scanf("%d", &n); for (int i = 1; i <= n; i++) {     printf("%d ", i); } --- ✅ 2. Sum of First N Natural Numbers Goal: Input n, output sum 1 + 2 + ... + n. int n, sum = 0; printf("Enter a number: "); scanf("%d", &n); for (int i = 1; i <= n; i++) {     sum += i; } printf("Sum = %d\n", sum); --- ✅ 3. Factorial of a Number Goal: Input n, calculate n!. int n, fact = 1; printf("Enter a number: "); scanf("%d", &n); for (int i = 1; i <= n; i++) {     fact *= i; } printf("Factorial = %d\n", fact); --- ✅ 4. Multiplication Table Goal: Input n, print tabl...

Part::1- COMPUTER BASIC QUESTION & ANSWER PART-1




. Q.1 How many major companies around the world manufacture microprocessors?

A: Only one company
 B: Tow companies
C: Three companies
 D: Many companies

Answer Tow companies (Intel and Motorola).




 Q.2 Which chip is used inside the apple new computers?
 A: G3
B: G4
 C: ATI
D: MAC03

 Answer G3


Q.3 Who is the father of computer?

A: Charles Newman
 B: Charles Babbage
 C: Henry Babbage
 D: Henry luce

Answer Charles Babbage

 Q.4 Charles Babbage designed two engine.
They are - A: Addition and Subtraction Engine
B: Analytic and Difference Engine
 C: Analytic and Digital engine
 D: Addition and Multiplication Engine

Answer Analytic and Difference Engine


Q.5 Which is an example of first generation computer?

A: EDVAC
 B: EDSAC
 C; ENIAC
 D; UNIVAC

Answer ENIAC

Q.6 Which computer generation the IBM 700 belongs to?

 A: First Generation
 B: Second Generation
 C: Third Generation
D: Fourth Generation

Answer Second Generation (1954 - 1962)

Q.7 Operating system is used in which generation of computer for the first time?

A: First Generation
 B: Second Generation
 C: Third Generation
 D: Fourth Generation

Answer Third Generation ( 1963 1971)
. 
Q.8 Which generation of computer used VLSI (Very Large Scale Integrated Chips) technology that brought bloom in the hardware industries
. 
A: First Generation
 B: Second Generation
 C: Third Generation
D: Fourth Generation
 E: Fifth Generation

Answer Fourth Generation (1972 - 1984)


 Q.9 Which generation of computer used CD ROM for the first time?

A: First Generation
B: Second Generation
 C: Third Generation
 D: Fourth Generation
 E: Fifth Generation

Answer Fifth Generation computer (1983 1990)

Q.10 Which generation of computer used Power-Book and Pentium microprocessor for the first time?

 A: Third Generation
 B: Fourth Generation
 C: Fifth Generation
 D: Sixth Generation

Answer Sixth Generation computer (1990 - till Now)

 Q.11 What is an another name of Personal Computer?

A: Micro-Computer
B: Private Computer
 C: Distinctive Computer
 D: Individual Computer

 Answer Microcomputer

Q.12 Which is the most common types of computer?

 A: Desktop
B: Notebook
 C: Server
 D: Laptop

 Answer Desktop


 Q.13 Which among the following computer provides greater speed than average for performing multi tasking?

 A: Personal Computer
 B: Notebook
 C: Workstation
D: Tablet PC

Answer Workstation

Q.14 Which is the newest development of full featured portable computer?

 A: A Notebook PC
 B: A Handheld PC
 C: Tablet PC
 D: Workstation

Answer Tablet PC

Q.15 Which is the powerful computer with special equipment and software that used for networking?

 A: Network Server
B: Workstation
C: Mainframe
 D: Supercomputer

 Answer Network Server

 Q.16 Which of the following is a mid range computer? A: Mainframe

B: Mini computer
 C: micro computer
D: Supercomputer

Answer Mini computer




Q.17 Which is the most powerful and physically largest computer?

 A: Workstation
B: Supercomputer
 C: Network server
 D: Gaming PC 

Answer Supercomputer

 Q.18 Which is the first electro-mechanical binary programmable computer?

A: Z1
 B: Intel 8084
C: IBM 007
D: Intel 8000

Answer Z1

Q.19 Which is the first computer in India?

A: ENIAC
B: HEC-2M
C: SZ 40/42
 D: Harwell CADET

Answer HEC-2M

Q.20 Which of the following exactly define computer?

 A: A machine which is lightweight and used for calculation.
B: A unit record machine
C: An electronic device that store and process data to give desire result.
D: A program instruction machine.

Answer An electronic device that store and process data to give desire result.

Comments

Post a Comment

Popular posts from this blog

python in brief

advance loop based C programmes