SlideShare a Scribd company logo
STAFF NAME: Dr. K.GEETHA
:
STAFF NAME: Dr.K.GEETHA, UNIT: II, SUB: FIT, CLASS: II M.COM
DATE DAY ORDER DAY HOUR MODE
14.9.2021 V TUE III REGULAR
15.9.2021 VI WED I REGULAR
16.9.2021 I THU II REGULAR
17.9.2021 II FRI III REGULAR
18.9.2021 III SAT I,IILAB REGULAR
21.9.2021 V TUE III REGULAR
22.9.2021 VI WED I REGULAR
23.9.2021 I THU II REGULAR
 Unit I Introduction to Computer - Classification of Digital Computer System -
Computer Architecture - Number - Compliments - Logic Gates - Truth Table -
Boolean Algebra - Table Simplification of Boolean Function
 Unit II Introduction to Computer Software - 'C', DBMS, RDBMS - Implementing
Number Sorting, Matrix Addition, Multiplication, Palindrome Checking, Searching an
Element an Array
 Unit III MS- WORD -Creating Word Document -Editing Text -Adding and Formatting
Numbers - Symbols -.Getting into Print - MS-EXCEL - Creating Tables Using EXCEL -
Using Tables and Creating Graphs - MS-ACCESS - Planning and Creating Tables -
forms - Modifying Tables -Creating relational Database- Form Design - Reports - MS-
POWERPOINT - Preparing Power Point Presentation for Marketing Products such as
CREDIT CARD, Newly Introduced Cosmetic item etc.,
 Unit IV Introduction to Internet -Resources of Internet - Hardware and Software
Requirement of
 Internet - Internet Service Providers - Creating an E-Mail Account - Sending and
Receiving Messages with Attachments to our friends account - Multimedia and its
Applications
 Unit V Application software - Accounting packages - Statistical packages -
Preparation of financial statements and statistical analysis
 Unit II Introduction to Computer Software - 'C',
DBMS, RDBMS - Implementing Number Sorting,
Matrix Addition, Multiplication, Palindrome
Checking, Searching an Element an ArraY
 Software is a set of programs, which is designed to
perform a well-defined function.
 A program is a sequence of instructions written to
solve a particular problem.
 There are two types of software −
 System Software
 Application Software
 System Software
 The system software is a collection of programs
designed to operate, control, and extend the
processing capabilities of the computer itself.
 System software is generally prepared by the
computer manufacturers.
 These software products comprise of programs
written in low-level languages, which interact with
the hardware at a very basic level.
 System software serves as the interface between
the hardware and the end users.
 System Software
 Some examples of system software are Operating
System, Compilers, Interpreter, Assemblers, etc.
 Application Software
 Application software products are designed to
satisfy a particular need of a particular
environment.
 All software applications prepared in the computer
lab can come under the category of Application
software.
 Application software may consist of a single
program, such as Microsoft's notepad for writing
and editing a simple text.
 It may also consist of a collection of programs,
often called a software package, which work
together to accomplish a task, such as a
spreadsheet package.
 Application Software
 Examples of Application software are the following
 Payroll Software
 Student Record Software
 Income Tax Software
 Railways Reservation Software
 Microsoft Office Suite Software
 Microsoft Word
 Microsoft Excel
 Microsoft PowerPoint
 C is a procedural programming language.
 It was initially developed by Dennis Ritchie in the
year 1972.
 It was mainly developed as a system programming
language to write an operating system.
 The main features of the C language include low-
level memory access, a simple set of keywords, and
a clean style.
 These features make C language suitable for system
programmings like an operating system or compiler
development.
 Many later languages have borrowed
syntax/features directly or indirectly from the C
language.
 Like syntax of Java, PHP, JavaScript, and many
other languages are mainly based on the C
language.
 C++ is nearly a superset of C language (Few
programs may compile in C, but not in C++).
The structure of a C program is as follows:
 #include <stdio.h>
 In a C program, all lines that start with # are
processed by a preprocessor .
 which is a program invoked by the compiler.
 The components of the above structure are:
 Header Files Inclusion:
A header file is a file with extension .h which contains C
function declarations and macro definitions to be shared
between several source files.
 Some of C Header files:
 stddef.h – Defines several useful types and macros.
 stdint.h – Defines exact width integer types.
 stdio.h – Defines core input and output functions
 stdlib.h – Defines numeric conversion functions, pseudo-
random network generator, memory allocation
 string.h – Defines string handling functions
 math.h – Defines common mathematical functions
 The components of the above structure are:
 Main Method Declaration:
 The next part of a C program is to declare the main()
function.
 There must be a starting point from where execution of
compiled C program begins.
 In C, the execution typically begins with the first line of
main().
 The syntax to declare the main function is:
 Syntax to Declare the main method:
 int main()
 The components of the above structure are:
 Variable Declaration:
 The next part of any C program is the variable
declaration.
 It refers to the variables that are to be used in the
function.
 No variable can be used without being declared.
 Also in a C program, the variables are to be declared
before any operation in the function.
 Example:
 int main()
 {
 int a; . .
 In C language, a pair of curly brackets define
scope and are mainly used in functions and control
statements like if, else, loops.
 All functions must start and end with curly
brackets.
 {
 …..}
 The components of the above structure are:
 Body:
 The body of a function in the C program, refers to
the operations that are performed in the functions.
 It can be anything like manipulations, searching,
sorting, printing, etc.
 Example:
 int main()
 {
 int a;
 printf("%d", a);
 }
 printf() is a standard library function to print
something on standard output.
 The semicolon at the end of printf() indicates line
termination.
 In C, a semicolon is always used to indicate end of
a statement.
 The components of the above structure are:
 Return Statement:
 The last part of any C program is the return statement.
 The return statement refers to the returning of the values from a function.
 This return statement and return value depend upon the return type of
the function.
 For example, if the return type is void, then there will be no return
statement.
 In any other case, there will be a return statement and the return value
will be of the type of the specified return type.
 Example:
 int main()
 {
 int a;
 printf("%d", a);
 return 0;
 }
 C is a compiled language.
 A compiler is a special tool that compiles the
program and converts it into the object file which
is machine readable.
 After the compilation process, the linker will
combine different object files and creates a single
executable file to run the program.
 The following diagram shows the execution of a ‘C’
program
 Variables in C
 A variable is a name of the memory location. It is
used to store data.
 Its value can be changed, and it can be reused many
times.
 It is a way to represent memory location through
symbol so that it can be easily identified.
 int a;
 float b;
 char c;
 Here, a, b, c are variables. The int, float, char are
the data types.
 Rules for defining variables
 A variable can have alphabets, digits, and
underscore.
 A variable name can start with the alphabet, and
underscore only. It can't start with a digit.
 No whitespace is allowed within the variable name.
 A variable name must not be any reserved word or
keyword, e.g. int, float, etc.
 Rules for defining variables
 Valid variable names:
 int a;
 int _ab;
 int a30;
 Invalid variable names:
 int 2;
 int a b;
 int long;
 Rules for defining variables
 Valid variable names:
 int a;
 int _ab;
 int a30;
 Invalid variable names:
 int 2;
 int a b;
 int long;
 There are many types of variables in c:
 local variable
 global variable
 static variable
 automatic variable
 external variable
 Local Variable
 A variable that is declared inside the function or
block is called a local variable.
 It must be declared at the start of the block.
 void function1()
 {
 int x=10;//local variable
 }
 Global Variable
 A variable that is declared outside the function or
block is called a global variable.
 Any function can change the value of the global
variable.
 It is available to all the functions.
 It must be declared at the start of the block.
 int value=20;//global variable
 void function1()
 {
 int x=10;//local variable
 }
 Static Variable
 A variable that is declared with the static
keyword is called static variable.
 It retains its value between multiple function
calls.
 void function1()
 {
 int x=10;//local variable
 static int y=10;//static variable
 x=x+1;
 y=y+1;
 printf("%d,%d",x,y);
 }
 Static Variable
 If you call this function many times, the local
variable will print the same value for each
function call, e.g, 11,11,11 and so on.
 But the static variable will print the
incremented value in each function call,
 e.g. 11, 12, 13 and so on.
 Automatic Variable
 All variables in C that are declared inside the
block, are automatic variables by default.
 We can explicitly declare an automatic variable
using auto keyword.
 void main()
 {
 int x=10;//local variable (also automatic)
 auto int y=20;//automatic variable
 }
 External Variable
 We can share a variable in multiple C source files
by using an external variable.
 To declare an external variable,
 Need to use extern keyword.
 extern int x=10;//external variable (also global)
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
 Data Types :
 The data type in C defines the amount of storage
allocated to variables
 The values that they can accept ,and the operation
that can be performed on those variables.
 C is rich in data types.
 There are three classes of Data-Type
 Primary Data Type
 Derived Data Type
 User Defined Data Type
 All C compiler support five type of fundamental data
type 1.
 Integer int 2,768 to 32,768 2.
 Character char -128 to 127 3.
 Floating Point float 3.4e-38 to 3.4e+38 4.
 Double Precision Floating Point double 1.7e-308 to
1.7e+308 5.
 Void Data Type void(used for function when no value is
to be return)
 All C compiler support five type of fundamental data
type 1.
 Integer int 2,768 to 32,768 2.
 Character char -128 to 127 3.
 Floating Point float 3.4e-38 to 3.4e+38 4.
 Double Precision Floating Point double 1.7e-308 to
1.7e+308 5.
 Void Data Type void(used for function when no value is
to be return)
 signed integers: range is equally divided among
negative and positive numbers (including 0)
 unsigned integers: range starts from 0 to the upper
positive number limit
 Hence, unsigned integers are used when:
 Negative numbers are not required
 Increase the range of positive number by double
 Double
 The most often used floating-point family data
type used.
 mantissa exponent
 The two integer parts of a floating-point value.
 Precision
 The effect on the domain of floating-point values
given a larger or smaller storage area in bytes.
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
 Integer data types
 include all whole numbers, that is numbers not having any fractional component.
 unsigned integral types,
 the leftmost bit, known as the most significant bit, represents 2^(N-1), where N is
the total number of bits in the data item.
 The range of possible values for an unsigned integer of N bits is from 0 to 2^N - 1. ( All
0s to all 1s )
 So for example, a 4-bit unsigned integer could range from 0 to 15, and an 8-bit
unsigned integer could range from 0 to 255.
 For signed integral types, the leftmost bit can be thought of as representing
a negative 2^(N-1).
 ( The real interpretation in the computer is more complicated, but if you think of it
this way you will get the right answers. )
 The most negative value would be the first bit a 1 and all other bits 0s, yielding
negative 2^(N-1).
 The most positive value would be the first bit a 0 and all other bits 1s, yielding 2^(N-1)
- 1.
 So for example, a 4-bit signed integer could range from -8 to +7, and an 8-bit signed
integer could range from -128 to +127.
 A signed integral type having all bits 1 is equal to -1, regardless of how many bits are in
the number.
 Signed and unsigned integers with the same number of total bits have the same
number of different possible values.
 Unsigned integers use one bit pattern ( all 0s ) to represent zero and all others to
represent positive values.
 Signed integers use half of the possible bit patterns to represent negative numbers, one
pattern to represent zero, and half minus 1 to represent positive values.
 An operator is a symbol that tells the compiler to
perform specific mathematical or logical functions.
 C language is rich in built-in operators and provides
the following types of operators −
 Arithmetic Operators
 Relational Operators
 Logical Operators
 Bitwise Operators
 Assignment Operators
Arithmetic Operators
 The following table shows all the arithmetic
operators supported by the C language.
 Assume variable A holds 10 and variable B holds 20
then − Operator Description Example
+ Adds two operands. A + B = 30
− Subtracts second operand from
the first.
A − B = -10
* Multiplies both operands. A * B = 200
/ Divides numerator by de-
numerator.
B / A = 2
% Modulus Operator and
remainder of after an integer
division.
B % A = 0
 Relational Operators
 The following table shows all the relational
operators supported by C. Assume variable A holds
10 and variable B holds 20 then −
Operator Description Example
== Checks if the values of two operands are equal
or not. If yes, then the condition becomes true.
(A == B) is not
true.
!= Checks if the values of two operands are equal
or not. If the values are not equal, then the
condition becomes true.
(A != B) is true.
> Checks if the value of left operand is greater
than the value of right operand. If yes, then the
condition becomes true.
(A > B) is not true.
< Checks if the value of left operand is less than
the value of right operand. If yes, then the
condition becomes true.
(A < B) is true.
>= Checks if the value of left operand is greater (A >= B) is not
 Logical Operators
 Following table shows all the logical operators
supported by C language. Assume variable A holds
1 and variable B holds 0, then −
Operator Description Example
&& Called Logical AND operator. If both the
operands are non-zero, then the condition
becomes true.
(A && B) is false.
|| Called Logical OR Operator. If any of the
two operands is non-zero, then the
condition becomes true.
(A || B) is true.
! Called Logical NOT Operator. It is used to
reverse the logical state of its operand. If a
condition is true, then Logical NOT
operator will make it false.
!(A && B) is true.
 Bitwise Operators
 Bitwise operator works on bits and perform bit-by-
bit operation. The truth tables for &, |, and ^ is as
follows −
p q p & q p | q p ^ q
0 0 0 0 0
0 1 0 1 1
1 1 1 1 0
1 0 0 1 1
 Bitwise Operators
 Assume A = 60 and B = 13 in binary format, they
will be as follows −
 A = 0011 1100
 B = 0000 1101
 -----------------
 A&B = 0000 1100
 A|B = 0011 1101
 A^B = 0011 0001
 ~A = 1100 0011
 Bitwise Operators
Operator Description Example
<< Binary Left Shift Operator. The left operands
value is moved left by the number of bits
specified by the right operand.
A << 2 = 240
i.e., 1111 0000
>> Binary Right Shift Operator. The left operands
value is moved right by the number of bits
specified by the right operand. A >> 2 = 15
i.e., 0000 1111
 Assignment Operators
 The following table lists the assignment operators
supported by the C language −
Operator Description Example
Operator Description Example
= Simple assignment operator. Assigns values from
right side operands to left side operand C = A + B will assign
the value of A + B to
C
-= Subtract AND assignment operator. It subtracts the
right operand from the left operand and assigns the
result to the left operand. C -= A is equivalent
to C = C - A
 To control the flow of program execution c
programming languages uses control statements.
 C provides two sytles of flow control:
 Branching (or) Selectional statements
 Looping ( or ) Iterative statements
 Branching is deciding what actions to take and
looping is deciding how many times to take a
certain action.
 Selection statement are used to make one-time
decisions in C Programming, that is, to execute
some code/s and ignore some code/s depending
upon the test expression.
 IF STATEMENT
 if (test expression)
 {
 statement/s to be executed
 if test expression is true;
 }
 The if statement checks whether the text expression
inside parenthesis () is true or not.
 If the test expression is true,
 statement/s inside the body of if statement is
executed but if test is false,
 statement/s inside body of if is ignored.
 Nested if...else statement
 (if...elseif....else Statement)
 The nested if...else statement is used when program requires more than
one test expression.
 Syntax of nested if...else statement.
 if (test expression1)
 {
 statement/s to be executed if test expression1 is true;
 }
 else if(test expression2)
 {
 statement/s to be executed
 if test expression1 is false and 2 is true;
 }
 else if (test expression 3)
 {
 statement/s to be executed if text expression1 and 2 are false and 3 is
true;
 } . . . else { statements to be executed if all test expressions are false; }
 Loops cause program to execute the certain block
of code repeatedly until test condition is false.
 Loops are used in performing repetitive task in
programming.
 Consider these scenarios: 1. We want to execute
some code/s 100 times. 2.
 We want to execute some code/s certain number
of times depending upon input from user.
 These types of task can be solved in programming
using loops.
 There are 3 types of loops in C programming:
 1. for loop
 2. while loop
 3. do...while loop
 for Loop Syntax
 for(initialization statement; test expression; update
statement)
 {
 code/s to be executed;
 }
 The initialization statement is executed only once at
the beginning of the for loop.
 Then the test expression is checked by the program.
 If the test expression is false, for loop is terminated.
 But if test expression is true then the code/s inside
body of for loop is executed and then update
expression is updated.
 This process repeats until test expression is false.
 WHILE LOOP STATEMENT:
 Syntax of while loop
 while (test expression)
 {
 statement/s to be executed.
 }
 The while loop checks whether the test expression is true or
not.
 If it is true, code/s inside the body of while loop is
executed,
 that is, code/s inside the braces { } are executed.
 Then again the test expression is checked whether test
expression is true or not.
 This process continues until the test expression becomes
false.
 Do...while loop
 do...while loop is very similar to while loop.
 Only difference between these two loops is that, in while
loops, test expression is checked at first but,
 in do...while loop code is executed at first then the
condition is checked.
 So, the code are executed at least once in do...while loops.
 Syntax of
 Do
 {
 some code/s;
 }
 while (test expression);
 At first codes inside body of do is executed. Then, the test
expression is checked. If it is true, code/s inside body of do
are executed again and the process continues until test
expression becomes false(zero).
 Decision making are needed when,
 the program encounters the situation to choose a
particular statement among many statements.
 If a programmer has to choose one block of
statement among many alternatives,
 nested if...else can be used but,
 this makes programming logic complex.
 This type of problem can be handled in C programming using
switch statement.
 Syntax of switch...case
 switch (n)
 {
 case constant1:
 code/s to be executed if n equals to constant1;
 break;
 case constant2:
 code/s to be executed if n equals to constant2;
 break; . . . default:
 code/s to be executed if n doesn't match to any cases;
 }
 The value of n is either an integer or a character in above syntax.
If the value of n matches constant in case, the relevant codes are
executed and control moves out of the switch statement. If the
doesn't matches any of the constant in case, then the default
codes are executed and control moves out of switch statement.
 In C programming,
 goto statement is used for altering the normal
sequence of program execution by transferring control
to some other part of the program.
 Syntax of goto statement
 goto label;
 .............
 .............
 .............
 label:
 statement;
 In this syntax, label is an identifier.
 When, the control of program reaches to goto
statement, the control of the program will jump to the
label: and executes the code below it.
 #include <stdio.h>
 #include <string.h>
 Void main()
 {
 char string1[20];
 int i, length; int flag = 0;
 printf("Enter a string:");
 scanf("%s", string1);
 length = strlen(string1);
 for(i=0;i < length ;i++)
 {
 if (flag) { printf("%s is not a palindrome", string1);
 }
 Else
 {
 printf("%s is a palindrome", string1);
 }
 Getch();;
 }
 #include <stdio.h>
 void main()
 {
 //fill your code
 int m, n;
 scanf(“%d %d”,&m,&n);
 int i, j;
 int mat1[m][n], mat2[m][n], mat3[m][n];
 for(i = 0; i < m; i++)
 {
 for(j = 0; j < n; j++)
 scanf(“%d”,&mat1[i][j]);
 }
 for(i = 0; i < n; i++)
 {
 for(j = 0; j < n; j++)
 scanf(“%d”,&mat2[i][j]);
 }
 for(i = 0; i < m; i++)
 {
 for(j = 0; j < n; j++)
 {
 mat3[i][j] = mat1[i][j] + mat2[i][j];
 }
 }
 for(i = 0; i < m; i++)
 {
 for(j = 0; j < n; j++)
 printf(“%d “, mat3[i][j]);
 printf(“n”);
 }
 Getch();
 }
 #include <stdio.h>
 int main()
 {
 int m, n, p, q, c, d, k, sum = 0;
 int mat1[10][10], mat2[10][10], mat3[10][10];
 printf(“Enter number of rows and columns of mat1 matrixn”);
 scanf(“%d%d”, &m, &n);
 printf(“Enter elements of matrix 1n”);
 for (c = 0; c < m; c++)
 for (d = 0; d < n; d++)
 scanf(“%d”, &mat1[c][d]);
 printf(“nEnter number of rows and columns of mat2 matrixn”);
 scanf(“%d%d”, &p, &q);
 If(n!=p)
 Printf(“n The matrixes can’t be multiplied with each other. n”);
 Else
 {
 Printf(“n Enter Elements of matrix 2 n”);
 for (c = 0; c < m; c++)
 for (d = 0; d < n; d++)
 scanf(“%d”, &mat1[c][d]);
 printf(“nEnter number of rows and columns of mat2 matrixn”);
 scanf(“%d%d”, &p, &q);
 if (n != p)
 printf(“nThe matrices can’t be multiplied with each other.n”);
 else
 {
 printf(“nEnter elements of matrix2n”);
 for (c = 0; c < p; c++)
 for (d = 0; d < q; d++)
 scanf(“%d”, &mat2[c][d]);
 for (c = 0; c < m; c++) {
 for (d = 0; d < q; d++) {
 for (k = 0; k < p; k++) {
 sum = sum + mat1[c][k]*mat2[k][d];
 }
 mat3[c][d] = sum;
 sum = 0;
 }
 }
 printf(“nProduct of the matrices:n”);
 for (c = 0; c < m; c++) {
 for (d = 0; d < q; d++)
 printf(“%dt”, mat3[c][d]);
 printf(“n”);
 }
 }
 getch();
 }
 #include <conio.h>
 int main()
 {
 int a[10000],i,n,key;

 printf("Enter size of the array : ");
 scanf("%d", &n);
 printf("Enter elements in array : ");
 for(i=0; i<n; i++)
 {
 scanf("%d",&a[i]);
 }
 printf("Enter the key : ");
 scanf("%d", &key);



 for(i=0; i<n; i++)
 {
 if(a[i]==key)
 {
 printf("element found ");
 return 0;
 }

 }

 printf("element not found");
 }
 Output
 Enter size of the array: 5
 Enter elements in array: 4
 6
 2
 1
 3
 Enter the key: 2
 element found
 Data are the principal resources of an
organization.
 Data stored in computer systems form a hierarchy
extending from a single bit to a database, the
major record-keeping entity of a firm.
 Each higher rung of this hierarchy is organized
from the components below it.
 Data are logically organized into:
 1. Bits (characters)
 2. Fields
 3. Records
 4. Files
 5. Databases
 Bit (Character) –
 a bit is the smallest unit of data representation (value
of a bit may be a 0 or 1).
 Eight bits make a byte which can represent a character
or a special symbol in a character code.
 Field -
 a field consists of a grouping of characters.
 A data field represents an attribute (a characteristic
or quality) of some entity (object, person, place, or
event).
 Record -
 a record represents a collection of attributes that
describe a real-world entity.
 A record consists of fields, with each field
describing an attribute of the entity.
 File -
 a group of related records.
 Files are frequently classified by the application
for which they are primarily used (employee file).
 A primary key in a file is the field (or fields)
whose value identifies a record among others in a
data file.
 Database -
 is an integrated collection of logically related
records or files.
 A database consolidates records previously stored
in separate files into a common pool of data
records that provides data for many applications.
 The data is managed by systems software called
database management systems (DBMS).
 The data stored in a database is independent of
the application programs using it and of the types
of secondary storage devices on which it is stored.
 Database -
 is an integrated collection of logically related
records or files.
 A database consolidates records previously stored
in separate files into a common pool of data
records that provides data for many applications.
 The data is managed by systems software called
database management systems (DBMS).
 The data stored in a database is independent of
the application programs using it and of the types
of secondary storage devices on which it is stored.
 A DBMS:
 1. Helps organize data for effective access by a
variety of users with different access needs and for
efficient storage.
 2. It makes it possible to create, access, maintain,
and control databases.
 3. Through a DBMS, data can be integrated and
presented on demand.
 A DBMS:
 Advantages of a database management approach:
 1. Avoiding uncontrolled data redundancy and
preventing inconsistency
 2. Program-data independence
 3. Flexible access to shared data
 4. Advantages of centralized control of data
 Data Definition: It is used for creation,
modification, and removal of definition that
defines the organization of data in the database.
 Data Updation: It is used for the insertion,
modification, and deletion of the actual data in
the database.
 Data Retrieval: It is used to retrieve the data from
the database which can be used by applications for
various purposes.
 User Administration: It is used for registering and
monitoring users, maintain data integrity,
enforcing data security, dealing with concurrency
control, monitoring performance and recovering
information corrupted by unexpected failure.
 It uses a digital repository established on a server to
store and manage the information.
 It can provide a clear and logical view of the process
that manipulates data.
 DBMS contains automatic backup and recovery
procedures.
 It contains ACID properties which maintain data in a
healthy state in case of failure.
 It can reduce the complex relationship between data.
 It is used to support manipulation and processing of
data.
 It is used to provide security of data.
 It can view the database from different viewpoints
according to the requirements of the user.
 Controls database redundancy: It can control data
redundancy because it stores all the data in one single
database file and that recorded data is placed in the
database.
 Data sharing: In DBMS, the authorized users of an
organization can share the data among multiple users.
 Easily Maintenance: It can be easily maintainable due
to the centralized nature of the database system.
 Reduce time: It reduces development time and
maintenance need.
 Backup: It provides backup and recovery subsystems
which create automatic backup of data
from hardware and software failures and restores the
data if required.
 multiple user interface: It provides different types of
user interfaces like graphical user interfaces,
application program interfaces
 Cost of Hardware and Software: It requires a high
speed of data processor and large memory size to
run DBMS software.
 Size: It occupies a large space of disks and large
memory to run them efficiently.
 Complexity: Database system creates additional
complexity and requirements.
 Higher impact of failure: Failure is highly
impacted the database because in most of the
organization, all the data stored in a single
database and if the database is damaged due to
electric failure or database corruption then the
data may be lost forever.
 A relational database is a collection of tables.
 Such a database is relatively easy for end users to
understand.
 Relational databases afford flexibility across the
data and are easy to understand and modify.
 1. Select, which selects from a specified table the
rows that satisfy a given condition.
 2. Project, which selects from a given table the
specified attribute values
 3. Join, which builds a new table from two
specified tables.
 The power of the relational model derives from
the join operation.
 It is precisely because records are related to one
another through a join operation, rather than
through links, that we do not need a predefined
access path.
 The join operation is also highly time-consuming,
requiring access to many records stored on disk in
order to find the needed records.
 RDBMS stands for relational database management
system.
 A relational model can be represented as a table of
rows and columns.
 A relational database has following major
components:
1. Table
2. Record or Tuple
3. Field or Column name or Attribute
4. Domain
5. Instance
6. Schema
7. Keys
 1. Table
 A table is a collection of data represented in rows
and columns. Each table has a name in database.
For example, the following table “employee”
stores the information of employee in database.
 Table : EMP
ID Name Age Salary
1 Adam 34 13000
2 Alex 28 15000
3 Stuart 20 18000
4 Ross 42 19020
 1. Table
 Table or relation: EMP
ID Name Age Salary
1 Adam 34 13000
2 Alex 28 15000
3 Stuart 20 18000
4 Ross 42 19020
 In Relational database model, a table is a
collection of data elements organised in terms of
rows and columns.
 A table is also considered as a convenient
representation of relations.
 But a table can have duplicate row of data while a
true relation cannot have duplicate data.
 Table is the most simplest form of data storage.
 Previous slide table is an example of an Employee
table.
 A single entry in a table is called
a Tuple or Record or Row.
 A tuple in a table represents a set of related data.
 For example, the above Employee table has 4
tuples/records/rows.
 Following is an example of single record or tuple.
1 Adam 34 13000
 Attribute Domain
 When an attribute is defined in a relation(table), it
is defined to hold only a certain type of values,
which is known as Attribute Domain.
 DBMS and RDBMS youtube link:
https://youtu.be/6BSlwKkgCYU

More Related Content

PDF
Unit 2 introduction to c programming
PPTX
C Programming Unit-1
PPTX
Introduction to C Unit 1
DOC
C notes diploma-ee-3rd-sem
PPTX
C Language ppt create by Anand & Sager.pptx
PPT
Chapter3
PPTX
Functions and Header files ver very useful
PDF
C programming course material
Unit 2 introduction to c programming
C Programming Unit-1
Introduction to C Unit 1
C notes diploma-ee-3rd-sem
C Language ppt create by Anand & Sager.pptx
Chapter3
Functions and Header files ver very useful
C programming course material

Similar to IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx (20)

PDF
Learn c language Important topics ( Easy & Logical, & smart way of learning)
DOC
Basic c
PPTX
C Programming UNIT 1.pptx
PPTX
Presentation on Function in C Programming
PDF
Pc module1
PPSX
C basics 4 std11(GujBoard)
PPT
The smartpath information systems c pro
DOCX
C LANGUAGE UNIT-1 PREPARED BY MVB REDDY
PDF
cp Module4(1)
PPTX
Lecture_5_-_Functions_in_C_Detailed.pptx
PDF
The C++ Programming Language
DOC
1. introduction to computer
PPTX
CH.4FUNCTIONS IN C_FYBSC(CS).pptx
PPTX
2.Overview of C language.pptx
PPTX
Lecture 1
PDF
Book management system
PPT
(Lect. 2 & 3) Introduction to C.ppt
PPTX
Sample for Simple C Program - R.D.Sivakumar
PDF
C notes.pdf
Learn c language Important topics ( Easy & Logical, & smart way of learning)
Basic c
C Programming UNIT 1.pptx
Presentation on Function in C Programming
Pc module1
C basics 4 std11(GujBoard)
The smartpath information systems c pro
C LANGUAGE UNIT-1 PREPARED BY MVB REDDY
cp Module4(1)
Lecture_5_-_Functions_in_C_Detailed.pptx
The C++ Programming Language
1. introduction to computer
CH.4FUNCTIONS IN C_FYBSC(CS).pptx
2.Overview of C language.pptx
Lecture 1
Book management system
(Lect. 2 & 3) Introduction to C.ppt
Sample for Simple C Program - R.D.Sivakumar
C notes.pdf
Ad

Recently uploaded (20)

PDF
Getting Started with Data Integration: FME Form 101
PDF
Mushroom cultivation and it's methods.pdf
PPTX
1. Introduction to Computer Programming.pptx
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PPTX
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
PDF
A novel scalable deep ensemble learning framework for big data classification...
PDF
1 - Historical Antecedents, Social Consideration.pdf
PDF
Univ-Connecticut-ChatGPT-Presentaion.pdf
PDF
project resource management chapter-09.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
PPTX
cloud_computing_Infrastucture_as_cloud_p
PDF
A comparative analysis of optical character recognition models for extracting...
PDF
DP Operators-handbook-extract for the Mautical Institute
PPTX
SOPHOS-XG Firewall Administrator PPT.pptx
Getting Started with Data Integration: FME Form 101
Mushroom cultivation and it's methods.pdf
1. Introduction to Computer Programming.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
Unlocking AI with Model Context Protocol (MCP)
Programs and apps: productivity, graphics, security and other tools
Assigned Numbers - 2025 - Bluetooth® Document
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
A novel scalable deep ensemble learning framework for big data classification...
1 - Historical Antecedents, Social Consideration.pdf
Univ-Connecticut-ChatGPT-Presentaion.pdf
project resource management chapter-09.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
cloud_computing_Infrastucture_as_cloud_p
A comparative analysis of optical character recognition models for extracting...
DP Operators-handbook-extract for the Mautical Institute
SOPHOS-XG Firewall Administrator PPT.pptx
Ad

IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx

  • 1. STAFF NAME: Dr. K.GEETHA
  • 2. : STAFF NAME: Dr.K.GEETHA, UNIT: II, SUB: FIT, CLASS: II M.COM DATE DAY ORDER DAY HOUR MODE 14.9.2021 V TUE III REGULAR 15.9.2021 VI WED I REGULAR 16.9.2021 I THU II REGULAR 17.9.2021 II FRI III REGULAR 18.9.2021 III SAT I,IILAB REGULAR 21.9.2021 V TUE III REGULAR 22.9.2021 VI WED I REGULAR 23.9.2021 I THU II REGULAR
  • 3.  Unit I Introduction to Computer - Classification of Digital Computer System - Computer Architecture - Number - Compliments - Logic Gates - Truth Table - Boolean Algebra - Table Simplification of Boolean Function  Unit II Introduction to Computer Software - 'C', DBMS, RDBMS - Implementing Number Sorting, Matrix Addition, Multiplication, Palindrome Checking, Searching an Element an Array  Unit III MS- WORD -Creating Word Document -Editing Text -Adding and Formatting Numbers - Symbols -.Getting into Print - MS-EXCEL - Creating Tables Using EXCEL - Using Tables and Creating Graphs - MS-ACCESS - Planning and Creating Tables - forms - Modifying Tables -Creating relational Database- Form Design - Reports - MS- POWERPOINT - Preparing Power Point Presentation for Marketing Products such as CREDIT CARD, Newly Introduced Cosmetic item etc.,  Unit IV Introduction to Internet -Resources of Internet - Hardware and Software Requirement of  Internet - Internet Service Providers - Creating an E-Mail Account - Sending and Receiving Messages with Attachments to our friends account - Multimedia and its Applications  Unit V Application software - Accounting packages - Statistical packages - Preparation of financial statements and statistical analysis
  • 4.  Unit II Introduction to Computer Software - 'C', DBMS, RDBMS - Implementing Number Sorting, Matrix Addition, Multiplication, Palindrome Checking, Searching an Element an ArraY
  • 5.  Software is a set of programs, which is designed to perform a well-defined function.  A program is a sequence of instructions written to solve a particular problem.  There are two types of software −  System Software  Application Software
  • 6.  System Software  The system software is a collection of programs designed to operate, control, and extend the processing capabilities of the computer itself.  System software is generally prepared by the computer manufacturers.  These software products comprise of programs written in low-level languages, which interact with the hardware at a very basic level.  System software serves as the interface between the hardware and the end users.
  • 7.  System Software  Some examples of system software are Operating System, Compilers, Interpreter, Assemblers, etc.
  • 8.  Application Software  Application software products are designed to satisfy a particular need of a particular environment.  All software applications prepared in the computer lab can come under the category of Application software.  Application software may consist of a single program, such as Microsoft's notepad for writing and editing a simple text.  It may also consist of a collection of programs, often called a software package, which work together to accomplish a task, such as a spreadsheet package.
  • 9.  Application Software  Examples of Application software are the following  Payroll Software  Student Record Software  Income Tax Software  Railways Reservation Software  Microsoft Office Suite Software  Microsoft Word  Microsoft Excel  Microsoft PowerPoint
  • 10.  C is a procedural programming language.  It was initially developed by Dennis Ritchie in the year 1972.  It was mainly developed as a system programming language to write an operating system.
  • 11.  The main features of the C language include low- level memory access, a simple set of keywords, and a clean style.  These features make C language suitable for system programmings like an operating system or compiler development.  Many later languages have borrowed syntax/features directly or indirectly from the C language.  Like syntax of Java, PHP, JavaScript, and many other languages are mainly based on the C language.  C++ is nearly a superset of C language (Few programs may compile in C, but not in C++).
  • 12. The structure of a C program is as follows:
  • 13.  #include <stdio.h>  In a C program, all lines that start with # are processed by a preprocessor .  which is a program invoked by the compiler.
  • 14.  The components of the above structure are:  Header Files Inclusion: A header file is a file with extension .h which contains C function declarations and macro definitions to be shared between several source files.  Some of C Header files:  stddef.h – Defines several useful types and macros.  stdint.h – Defines exact width integer types.  stdio.h – Defines core input and output functions  stdlib.h – Defines numeric conversion functions, pseudo- random network generator, memory allocation  string.h – Defines string handling functions  math.h – Defines common mathematical functions
  • 15.  The components of the above structure are:  Main Method Declaration:  The next part of a C program is to declare the main() function.  There must be a starting point from where execution of compiled C program begins.  In C, the execution typically begins with the first line of main().  The syntax to declare the main function is:  Syntax to Declare the main method:  int main()
  • 16.  The components of the above structure are:  Variable Declaration:  The next part of any C program is the variable declaration.  It refers to the variables that are to be used in the function.  No variable can be used without being declared.  Also in a C program, the variables are to be declared before any operation in the function.  Example:  int main()  {  int a; . .
  • 17.  In C language, a pair of curly brackets define scope and are mainly used in functions and control statements like if, else, loops.  All functions must start and end with curly brackets.  {  …..}
  • 18.  The components of the above structure are:  Body:  The body of a function in the C program, refers to the operations that are performed in the functions.  It can be anything like manipulations, searching, sorting, printing, etc.  Example:  int main()  {  int a;  printf("%d", a);  }
  • 19.  printf() is a standard library function to print something on standard output.  The semicolon at the end of printf() indicates line termination.  In C, a semicolon is always used to indicate end of a statement.
  • 20.  The components of the above structure are:  Return Statement:  The last part of any C program is the return statement.  The return statement refers to the returning of the values from a function.  This return statement and return value depend upon the return type of the function.  For example, if the return type is void, then there will be no return statement.  In any other case, there will be a return statement and the return value will be of the type of the specified return type.  Example:  int main()  {  int a;  printf("%d", a);  return 0;  }
  • 21.  C is a compiled language.  A compiler is a special tool that compiles the program and converts it into the object file which is machine readable.  After the compilation process, the linker will combine different object files and creates a single executable file to run the program.  The following diagram shows the execution of a ‘C’ program
  • 22.  Variables in C  A variable is a name of the memory location. It is used to store data.  Its value can be changed, and it can be reused many times.  It is a way to represent memory location through symbol so that it can be easily identified.  int a;  float b;  char c;  Here, a, b, c are variables. The int, float, char are the data types.
  • 23.  Rules for defining variables  A variable can have alphabets, digits, and underscore.  A variable name can start with the alphabet, and underscore only. It can't start with a digit.  No whitespace is allowed within the variable name.  A variable name must not be any reserved word or keyword, e.g. int, float, etc.
  • 24.  Rules for defining variables  Valid variable names:  int a;  int _ab;  int a30;  Invalid variable names:  int 2;  int a b;  int long;
  • 25.  Rules for defining variables  Valid variable names:  int a;  int _ab;  int a30;  Invalid variable names:  int 2;  int a b;  int long;
  • 26.  There are many types of variables in c:  local variable  global variable  static variable  automatic variable  external variable
  • 27.  Local Variable  A variable that is declared inside the function or block is called a local variable.  It must be declared at the start of the block.  void function1()  {  int x=10;//local variable  }
  • 28.  Global Variable  A variable that is declared outside the function or block is called a global variable.  Any function can change the value of the global variable.  It is available to all the functions.  It must be declared at the start of the block.  int value=20;//global variable  void function1()  {  int x=10;//local variable  }
  • 29.  Static Variable  A variable that is declared with the static keyword is called static variable.  It retains its value between multiple function calls.  void function1()  {  int x=10;//local variable  static int y=10;//static variable  x=x+1;  y=y+1;  printf("%d,%d",x,y);  }
  • 30.  Static Variable  If you call this function many times, the local variable will print the same value for each function call, e.g, 11,11,11 and so on.  But the static variable will print the incremented value in each function call,  e.g. 11, 12, 13 and so on.
  • 31.  Automatic Variable  All variables in C that are declared inside the block, are automatic variables by default.  We can explicitly declare an automatic variable using auto keyword.  void main()  {  int x=10;//local variable (also automatic)  auto int y=20;//automatic variable  }
  • 32.  External Variable  We can share a variable in multiple C source files by using an external variable.  To declare an external variable,  Need to use extern keyword.  extern int x=10;//external variable (also global)
  • 34.  Data Types :  The data type in C defines the amount of storage allocated to variables  The values that they can accept ,and the operation that can be performed on those variables.  C is rich in data types.  There are three classes of Data-Type  Primary Data Type  Derived Data Type  User Defined Data Type
  • 35.  All C compiler support five type of fundamental data type 1.  Integer int 2,768 to 32,768 2.  Character char -128 to 127 3.  Floating Point float 3.4e-38 to 3.4e+38 4.  Double Precision Floating Point double 1.7e-308 to 1.7e+308 5.  Void Data Type void(used for function when no value is to be return)
  • 36.  All C compiler support five type of fundamental data type 1.  Integer int 2,768 to 32,768 2.  Character char -128 to 127 3.  Floating Point float 3.4e-38 to 3.4e+38 4.  Double Precision Floating Point double 1.7e-308 to 1.7e+308 5.  Void Data Type void(used for function when no value is to be return)
  • 37.  signed integers: range is equally divided among negative and positive numbers (including 0)  unsigned integers: range starts from 0 to the upper positive number limit  Hence, unsigned integers are used when:  Negative numbers are not required  Increase the range of positive number by double
  • 38.  Double  The most often used floating-point family data type used.  mantissa exponent  The two integer parts of a floating-point value.  Precision  The effect on the domain of floating-point values given a larger or smaller storage area in bytes.
  • 40.  Integer data types  include all whole numbers, that is numbers not having any fractional component.  unsigned integral types,  the leftmost bit, known as the most significant bit, represents 2^(N-1), where N is the total number of bits in the data item.  The range of possible values for an unsigned integer of N bits is from 0 to 2^N - 1. ( All 0s to all 1s )  So for example, a 4-bit unsigned integer could range from 0 to 15, and an 8-bit unsigned integer could range from 0 to 255.  For signed integral types, the leftmost bit can be thought of as representing a negative 2^(N-1).  ( The real interpretation in the computer is more complicated, but if you think of it this way you will get the right answers. )  The most negative value would be the first bit a 1 and all other bits 0s, yielding negative 2^(N-1).  The most positive value would be the first bit a 0 and all other bits 1s, yielding 2^(N-1) - 1.  So for example, a 4-bit signed integer could range from -8 to +7, and an 8-bit signed integer could range from -128 to +127.  A signed integral type having all bits 1 is equal to -1, regardless of how many bits are in the number.  Signed and unsigned integers with the same number of total bits have the same number of different possible values.  Unsigned integers use one bit pattern ( all 0s ) to represent zero and all others to represent positive values.  Signed integers use half of the possible bit patterns to represent negative numbers, one pattern to represent zero, and half minus 1 to represent positive values.
  • 41.  An operator is a symbol that tells the compiler to perform specific mathematical or logical functions.  C language is rich in built-in operators and provides the following types of operators −  Arithmetic Operators  Relational Operators  Logical Operators  Bitwise Operators  Assignment Operators
  • 42. Arithmetic Operators  The following table shows all the arithmetic operators supported by the C language.  Assume variable A holds 10 and variable B holds 20 then − Operator Description Example + Adds two operands. A + B = 30 − Subtracts second operand from the first. A − B = -10 * Multiplies both operands. A * B = 200 / Divides numerator by de- numerator. B / A = 2 % Modulus Operator and remainder of after an integer division. B % A = 0
  • 43.  Relational Operators  The following table shows all the relational operators supported by C. Assume variable A holds 10 and variable B holds 20 then − Operator Description Example == Checks if the values of two operands are equal or not. If yes, then the condition becomes true. (A == B) is not true. != Checks if the values of two operands are equal or not. If the values are not equal, then the condition becomes true. (A != B) is true. > Checks if the value of left operand is greater than the value of right operand. If yes, then the condition becomes true. (A > B) is not true. < Checks if the value of left operand is less than the value of right operand. If yes, then the condition becomes true. (A < B) is true. >= Checks if the value of left operand is greater (A >= B) is not
  • 44.  Logical Operators  Following table shows all the logical operators supported by C language. Assume variable A holds 1 and variable B holds 0, then − Operator Description Example && Called Logical AND operator. If both the operands are non-zero, then the condition becomes true. (A && B) is false. || Called Logical OR Operator. If any of the two operands is non-zero, then the condition becomes true. (A || B) is true. ! Called Logical NOT Operator. It is used to reverse the logical state of its operand. If a condition is true, then Logical NOT operator will make it false. !(A && B) is true.
  • 45.  Bitwise Operators  Bitwise operator works on bits and perform bit-by- bit operation. The truth tables for &, |, and ^ is as follows − p q p & q p | q p ^ q 0 0 0 0 0 0 1 0 1 1 1 1 1 1 0 1 0 0 1 1
  • 46.  Bitwise Operators  Assume A = 60 and B = 13 in binary format, they will be as follows −  A = 0011 1100  B = 0000 1101  -----------------  A&B = 0000 1100  A|B = 0011 1101  A^B = 0011 0001  ~A = 1100 0011
  • 47.  Bitwise Operators Operator Description Example << Binary Left Shift Operator. The left operands value is moved left by the number of bits specified by the right operand. A << 2 = 240 i.e., 1111 0000 >> Binary Right Shift Operator. The left operands value is moved right by the number of bits specified by the right operand. A >> 2 = 15 i.e., 0000 1111
  • 48.  Assignment Operators  The following table lists the assignment operators supported by the C language − Operator Description Example Operator Description Example = Simple assignment operator. Assigns values from right side operands to left side operand C = A + B will assign the value of A + B to C -= Subtract AND assignment operator. It subtracts the right operand from the left operand and assigns the result to the left operand. C -= A is equivalent to C = C - A
  • 49.  To control the flow of program execution c programming languages uses control statements.  C provides two sytles of flow control:  Branching (or) Selectional statements  Looping ( or ) Iterative statements
  • 50.  Branching is deciding what actions to take and looping is deciding how many times to take a certain action.  Selection statement are used to make one-time decisions in C Programming, that is, to execute some code/s and ignore some code/s depending upon the test expression.
  • 51.  IF STATEMENT  if (test expression)  {  statement/s to be executed  if test expression is true;  }  The if statement checks whether the text expression inside parenthesis () is true or not.  If the test expression is true,  statement/s inside the body of if statement is executed but if test is false,  statement/s inside body of if is ignored.
  • 52.  Nested if...else statement  (if...elseif....else Statement)  The nested if...else statement is used when program requires more than one test expression.  Syntax of nested if...else statement.  if (test expression1)  {  statement/s to be executed if test expression1 is true;  }  else if(test expression2)  {  statement/s to be executed  if test expression1 is false and 2 is true;  }  else if (test expression 3)  {  statement/s to be executed if text expression1 and 2 are false and 3 is true;  } . . . else { statements to be executed if all test expressions are false; }
  • 53.  Loops cause program to execute the certain block of code repeatedly until test condition is false.  Loops are used in performing repetitive task in programming.  Consider these scenarios: 1. We want to execute some code/s 100 times. 2.  We want to execute some code/s certain number of times depending upon input from user.  These types of task can be solved in programming using loops.  There are 3 types of loops in C programming:  1. for loop  2. while loop  3. do...while loop
  • 54.  for Loop Syntax  for(initialization statement; test expression; update statement)  {  code/s to be executed;  }  The initialization statement is executed only once at the beginning of the for loop.  Then the test expression is checked by the program.  If the test expression is false, for loop is terminated.  But if test expression is true then the code/s inside body of for loop is executed and then update expression is updated.  This process repeats until test expression is false.
  • 55.  WHILE LOOP STATEMENT:  Syntax of while loop  while (test expression)  {  statement/s to be executed.  }  The while loop checks whether the test expression is true or not.  If it is true, code/s inside the body of while loop is executed,  that is, code/s inside the braces { } are executed.  Then again the test expression is checked whether test expression is true or not.  This process continues until the test expression becomes false.
  • 56.  Do...while loop  do...while loop is very similar to while loop.  Only difference between these two loops is that, in while loops, test expression is checked at first but,  in do...while loop code is executed at first then the condition is checked.  So, the code are executed at least once in do...while loops.  Syntax of  Do  {  some code/s;  }  while (test expression);  At first codes inside body of do is executed. Then, the test expression is checked. If it is true, code/s inside body of do are executed again and the process continues until test expression becomes false(zero).
  • 57.  Decision making are needed when,  the program encounters the situation to choose a particular statement among many statements.  If a programmer has to choose one block of statement among many alternatives,  nested if...else can be used but,  this makes programming logic complex.
  • 58.  This type of problem can be handled in C programming using switch statement.  Syntax of switch...case  switch (n)  {  case constant1:  code/s to be executed if n equals to constant1;  break;  case constant2:  code/s to be executed if n equals to constant2;  break; . . . default:  code/s to be executed if n doesn't match to any cases;  }  The value of n is either an integer or a character in above syntax. If the value of n matches constant in case, the relevant codes are executed and control moves out of the switch statement. If the doesn't matches any of the constant in case, then the default codes are executed and control moves out of switch statement.
  • 59.  In C programming,  goto statement is used for altering the normal sequence of program execution by transferring control to some other part of the program.  Syntax of goto statement  goto label;  .............  .............  .............  label:  statement;  In this syntax, label is an identifier.  When, the control of program reaches to goto statement, the control of the program will jump to the label: and executes the code below it.
  • 60.  #include <stdio.h>  #include <string.h>  Void main()  {  char string1[20];  int i, length; int flag = 0;  printf("Enter a string:");  scanf("%s", string1);  length = strlen(string1);  for(i=0;i < length ;i++)  {
  • 61.  if (flag) { printf("%s is not a palindrome", string1);  }  Else  {  printf("%s is a palindrome", string1);  }  Getch();;  }
  • 62.  #include <stdio.h>  void main()  {  //fill your code  int m, n;  scanf(“%d %d”,&m,&n);  int i, j;  int mat1[m][n], mat2[m][n], mat3[m][n];  for(i = 0; i < m; i++)  {  for(j = 0; j < n; j++)  scanf(“%d”,&mat1[i][j]);  }  for(i = 0; i < n; i++)  {  for(j = 0; j < n; j++)  scanf(“%d”,&mat2[i][j]);  }
  • 63.  for(i = 0; i < m; i++)  {  for(j = 0; j < n; j++)  {  mat3[i][j] = mat1[i][j] + mat2[i][j];  }  }  for(i = 0; i < m; i++)  {  for(j = 0; j < n; j++)  printf(“%d “, mat3[i][j]);  printf(“n”);  }  Getch();  }
  • 64.  #include <stdio.h>  int main()  {  int m, n, p, q, c, d, k, sum = 0;  int mat1[10][10], mat2[10][10], mat3[10][10];  printf(“Enter number of rows and columns of mat1 matrixn”);  scanf(“%d%d”, &m, &n);  printf(“Enter elements of matrix 1n”);  for (c = 0; c < m; c++)  for (d = 0; d < n; d++)  scanf(“%d”, &mat1[c][d]);  printf(“nEnter number of rows and columns of mat2 matrixn”);  scanf(“%d%d”, &p, &q);
  • 65.  If(n!=p)  Printf(“n The matrixes can’t be multiplied with each other. n”);  Else  {  Printf(“n Enter Elements of matrix 2 n”);  for (c = 0; c < m; c++)  for (d = 0; d < n; d++)  scanf(“%d”, &mat1[c][d]);  printf(“nEnter number of rows and columns of mat2 matrixn”);  scanf(“%d%d”, &p, &q);  if (n != p)  printf(“nThe matrices can’t be multiplied with each other.n”);  else  {  printf(“nEnter elements of matrix2n”);  for (c = 0; c < p; c++)  for (d = 0; d < q; d++)  scanf(“%d”, &mat2[c][d]);
  • 66.  for (c = 0; c < m; c++) {  for (d = 0; d < q; d++) {  for (k = 0; k < p; k++) {  sum = sum + mat1[c][k]*mat2[k][d];  }  mat3[c][d] = sum;  sum = 0;  }  }  printf(“nProduct of the matrices:n”);  for (c = 0; c < m; c++) {  for (d = 0; d < q; d++)  printf(“%dt”, mat3[c][d]);  printf(“n”);  }  }  getch();  }
  • 67.  #include <conio.h>  int main()  {  int a[10000],i,n,key;   printf("Enter size of the array : ");  scanf("%d", &n);  printf("Enter elements in array : ");  for(i=0; i<n; i++)  {  scanf("%d",&a[i]);  }  printf("Enter the key : ");  scanf("%d", &key);  
  • 68.   for(i=0; i<n; i++)  {  if(a[i]==key)  {  printf("element found ");  return 0;  }   }   printf("element not found");  }
  • 69.  Output  Enter size of the array: 5  Enter elements in array: 4  6  2  1  3  Enter the key: 2  element found
  • 70.  Data are the principal resources of an organization.  Data stored in computer systems form a hierarchy extending from a single bit to a database, the major record-keeping entity of a firm.  Each higher rung of this hierarchy is organized from the components below it.
  • 71.  Data are logically organized into:  1. Bits (characters)  2. Fields  3. Records  4. Files  5. Databases
  • 72.  Bit (Character) –  a bit is the smallest unit of data representation (value of a bit may be a 0 or 1).  Eight bits make a byte which can represent a character or a special symbol in a character code.  Field -  a field consists of a grouping of characters.  A data field represents an attribute (a characteristic or quality) of some entity (object, person, place, or event).
  • 73.  Record -  a record represents a collection of attributes that describe a real-world entity.  A record consists of fields, with each field describing an attribute of the entity.
  • 74.  File -  a group of related records.  Files are frequently classified by the application for which they are primarily used (employee file).  A primary key in a file is the field (or fields) whose value identifies a record among others in a data file.
  • 75.  Database -  is an integrated collection of logically related records or files.  A database consolidates records previously stored in separate files into a common pool of data records that provides data for many applications.  The data is managed by systems software called database management systems (DBMS).  The data stored in a database is independent of the application programs using it and of the types of secondary storage devices on which it is stored.
  • 76.  Database -  is an integrated collection of logically related records or files.  A database consolidates records previously stored in separate files into a common pool of data records that provides data for many applications.  The data is managed by systems software called database management systems (DBMS).  The data stored in a database is independent of the application programs using it and of the types of secondary storage devices on which it is stored.
  • 77.  A DBMS:  1. Helps organize data for effective access by a variety of users with different access needs and for efficient storage.  2. It makes it possible to create, access, maintain, and control databases.  3. Through a DBMS, data can be integrated and presented on demand.
  • 78.  A DBMS:  Advantages of a database management approach:  1. Avoiding uncontrolled data redundancy and preventing inconsistency  2. Program-data independence  3. Flexible access to shared data  4. Advantages of centralized control of data
  • 79.  Data Definition: It is used for creation, modification, and removal of definition that defines the organization of data in the database.  Data Updation: It is used for the insertion, modification, and deletion of the actual data in the database.
  • 80.  Data Retrieval: It is used to retrieve the data from the database which can be used by applications for various purposes.  User Administration: It is used for registering and monitoring users, maintain data integrity, enforcing data security, dealing with concurrency control, monitoring performance and recovering information corrupted by unexpected failure.
  • 81.  It uses a digital repository established on a server to store and manage the information.  It can provide a clear and logical view of the process that manipulates data.  DBMS contains automatic backup and recovery procedures.  It contains ACID properties which maintain data in a healthy state in case of failure.  It can reduce the complex relationship between data.  It is used to support manipulation and processing of data.  It is used to provide security of data.  It can view the database from different viewpoints according to the requirements of the user.
  • 82.  Controls database redundancy: It can control data redundancy because it stores all the data in one single database file and that recorded data is placed in the database.  Data sharing: In DBMS, the authorized users of an organization can share the data among multiple users.  Easily Maintenance: It can be easily maintainable due to the centralized nature of the database system.  Reduce time: It reduces development time and maintenance need.  Backup: It provides backup and recovery subsystems which create automatic backup of data from hardware and software failures and restores the data if required.  multiple user interface: It provides different types of user interfaces like graphical user interfaces, application program interfaces
  • 83.  Cost of Hardware and Software: It requires a high speed of data processor and large memory size to run DBMS software.  Size: It occupies a large space of disks and large memory to run them efficiently.  Complexity: Database system creates additional complexity and requirements.  Higher impact of failure: Failure is highly impacted the database because in most of the organization, all the data stored in a single database and if the database is damaged due to electric failure or database corruption then the data may be lost forever.
  • 84.  A relational database is a collection of tables.  Such a database is relatively easy for end users to understand.  Relational databases afford flexibility across the data and are easy to understand and modify.  1. Select, which selects from a specified table the rows that satisfy a given condition.  2. Project, which selects from a given table the specified attribute values  3. Join, which builds a new table from two specified tables.
  • 85.  The power of the relational model derives from the join operation.  It is precisely because records are related to one another through a join operation, rather than through links, that we do not need a predefined access path.  The join operation is also highly time-consuming, requiring access to many records stored on disk in order to find the needed records.
  • 86.  RDBMS stands for relational database management system.  A relational model can be represented as a table of rows and columns.  A relational database has following major components: 1. Table 2. Record or Tuple 3. Field or Column name or Attribute 4. Domain 5. Instance 6. Schema 7. Keys
  • 87.  1. Table  A table is a collection of data represented in rows and columns. Each table has a name in database. For example, the following table “employee” stores the information of employee in database.  Table : EMP ID Name Age Salary 1 Adam 34 13000 2 Alex 28 15000 3 Stuart 20 18000 4 Ross 42 19020
  • 88.  1. Table  Table or relation: EMP ID Name Age Salary 1 Adam 34 13000 2 Alex 28 15000 3 Stuart 20 18000 4 Ross 42 19020
  • 89.  In Relational database model, a table is a collection of data elements organised in terms of rows and columns.  A table is also considered as a convenient representation of relations.  But a table can have duplicate row of data while a true relation cannot have duplicate data.  Table is the most simplest form of data storage.  Previous slide table is an example of an Employee table.
  • 90.  A single entry in a table is called a Tuple or Record or Row.  A tuple in a table represents a set of related data.  For example, the above Employee table has 4 tuples/records/rows.  Following is an example of single record or tuple. 1 Adam 34 13000
  • 91.  Attribute Domain  When an attribute is defined in a relation(table), it is defined to hold only a certain type of values, which is known as Attribute Domain.  DBMS and RDBMS youtube link: https://youtu.be/6BSlwKkgCYU