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...

Computer Storage Device Basic Questions


Q.1 In optical media group which is the latest addition from the following?
 A: CD-RW DVD-RW

B: Blu-Ray Disk
 C: DVD-RAM
D: DVD-ROM
Answer:: DVD-RAM

Q.2 Which have the largest memory storing capacity from optical media group?
A: DVD-RW
B: DVD-ROM
C: Blu-Ray
 D: DVD-RAM
Answer:: Blu-Ray

Q.3 Which of the following disks can be record only once?
A: CD-R and DVD-R
B: CD-RW and DVD-RW
C: Blu-Ray Disk
 D: CD-RAM and DVD-RAM
Answer:: CD-R and DVD-R

Q.4 In the computer the term “Backing” means –
 A: Starting the computer
B: Splitting a large file
C: Copy files and data into other storage
D: Protect computer from virus
Answer:: Copy files and data into other storage

Q.5 Which method of access is used where access speed is vital?
 A: Serial access
B: Direct access
C: Indirect access
 D: Search access

 Answer:: Direct access

Q.6 Which is a very thin strip of plastic coated in a magnetic layer?
A: Magnetic Tap
B: Electric Dipole Tap
C: Floppy Disk
D: Hard Disk
Answer:: Magnetic Tape

Q.7 Which storage type is used in the older version of some computers?
A: Solid State Drive
B: Hard Disk Drive (HDD)
 C: Floppy Disk Drive
D: Portable hard disk
Answer:: Floppy disk drive

Q.8 Which storage type is used in the modern digital cameras, mobile phones, Mp3 players etc..?
 A: Pendrive
B: Flash memory card
 C: Optical drive
D: Floppy drive
Answer:: Flash memory card

Q.9 Which of the following uses solid state drive (SSD)?
A: Solid State Baking Store
 B: Microchip
C: Nano Chip
D: Macro Chip
Answer:: Solid state baking store

Q.10 Basically what kind is the secondary storage memory?
A: Volatile Memory
B: Non-volatile Memory
C: Random access memory
D: All of above
Answer:: Non-volatile memory

Q.11 The process by which a storage disk can be divided into some storage drive sector is called –
 A: Tracking
B: Formatting
C: Partitioning
D: Allotting
Answer:: Partitioning

Q.12 The program that use to write CD-RW is called –
A: VDF packet writer
B: VFD packet writer
 C: DVF packet writer
D: FVD packet writer
Answer:: VDF packet writer

Comments

Popular posts from this blog

python in brief

advance loop based C programmes