0% found this document useful (0 votes)
6 views8 pages

C Programming-1

Structured Programming is a programming paradigm that enhances software clarity, quality, and development time through organized code, featuring modularity, top-down design, code reusability, and sequential flow of control. The document also outlines various data types in C, including basic, derived, user-defined, and void types, as well as different types of constants such as integer, floating-point, character, string, symbolic, and enumeration constants. Additionally, it describes operators in C and the three main types of loops: for, while, and do-while.

Uploaded by

staraakash9155
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views8 pages

C Programming-1

Structured Programming is a programming paradigm that enhances software clarity, quality, and development time through organized code, featuring modularity, top-down design, code reusability, and sequential flow of control. The document also outlines various data types in C, including basic, derived, user-defined, and void types, as well as different types of constants such as integer, floating-point, character, string, symbolic, and enumeration constants. Additionally, it describes operators in C and the three main types of loops: for, while, and do-while.

Uploaded by

staraakash9155
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

Akash Kumar Pathak

1. W h a t do you mean by st r u ct u r e programming? Discuss it s various fe atu res.

S tr uc tur ed Programming is a programming paradigm aimed a t improving t h e


cl arity , q ua li ty , and developm ent t im e o f s o f t w a r e by using w e l l - organized
code. I t emphasizes a logical s tr uc t ur e in programs, making t h em easier t o
read, debug, and m odify .

Features o f St ruct u re d Programming


Mo du larit y
T o p- Down Design
Code Reusability
Sequential Flow o f Control
2.Explain various d a t a types used in C

Basic D at a Types
Derived D at a Types
User-Defined D at a Types
Void D at a Type
3.Explain d i f f e r e n t types o f con stan t used in C
In C, constants re fe r t o f i x e d values t h a t do n o t change during t h e execution o f
a program. There are several types o f constants in C, categorized based on thei r
d a ta t y p e and representation. Here are t h e main types:

Integer Constants

Float ing-Point Constants

Character Constants

String Constants

Symbolic Constants

Enumeration Constants
4. Wh at are t h e various operators used in c.

In C, operators are symbols t h a t pe rf orm operations on variables and values.


They can be classified in t o d i f f e r e n t types based on th eir f u n ct io n a li t y

Arit hm et ic Operators
Relational (Comparison) Operators
Logical Operators
Bitwise Operators
Assignment Operators
Increment and Decrement Operators
Ternary (Conditional) Operator
Type Casting Operator
5. Explain d i f f e r e n t types o f loop in C
In C, loops are used t o execu te a block o f code repeatedly as long as
a specified condition is me t. There are three main types o f loops in C:

1. f o r Loop

#include <stdio.h>
i n t main() {
f o r ( in t i = 1; i <= 5; i++) {
pr intf("% d ", i);
}
re tu rn 0;
}
2. while Loop

#include <stdio.h>
i n t main() {
i n t i = 1;
while (i <= 5) {
print f("%d ", i);
i++;
}
re tu rn 0;
}
3. d o - while Loop

#include <stdio.h>
i n t main() {
i n t i = 1;
do {
pr in tf( "%d ", i);
i++;
} while (i <= 5);
r et ur n 0;
}

You might also like