Program. SUBJECT: ACP (C - Programming) Array Program. // Find the minimum number from given N element. Prepared By : Dhaval R.
|
|
- Amos Morris
- 6 years ago
- Views:
Transcription
1 Program // Find the minimum number from given N element. #include<stdio.h> #include<conio.h> void main() int a[50],i,n,min; clrscr(); printf("\n Enter array size : "); scanf("%d",&n); printf("\n Enter No. : "); scanf("%d",&a[i]); min=a[0]; if(a[i]<min) 1
2 min=a[i]; printf("\n Minimum Number = %d",min); getch(); // Find the maximum number from given N element. #include<stdio.h> #include<conio.h> void main() int a[50],i,n,max; 2
3 clrscr(); printf("\n Enter array size : "); scanf("%d",&n); printf("\n Enter No. : "); scanf("%d",&a[i]); max=a[0]; if(a[i]>max) max=a[i]; printf("\n Maximum Number = %d",max); getch(); 3
4 // Insert the element in array at given position. #include<stdio.h> #include<conio.h> void main() int a[50],i,n,x,p; clrscr(); printf("\n Enter array size : "); scanf("%d",&n); printf("enter a[%d] : ",i); scanf("%d",&a[i]); 4
5 printf("\n Enter new element : "); scanf("%d",&x); printf("\n Enter new element position : "); scanf("%d",&p); if(p>0 && p<=n) i=n; while(p!=(i+1)) a[i]=a[i-1]; i=i-1; a[i]=x; printf("\n"); for(i=0;i<n+1;i=i+1) printf("\n a[%d] = %d",i,a[i]); else 5
6 printf("\n Position Not Found"); getch(); // Delete the element from array at given position. #include<stdio.h> #include<conio.h> void main() int a[50],i,n,p; clrscr(); 6
7 printf("\n Enter array size : "); scanf("%d",&n); printf("enter a[%d] : ",i); scanf("%d",&a[i]); printf("\n Enter position for delete: "); scanf("%d",&p); if(p>0 && p<=n) for(i=p;i<(n-1);i=i+1) a[i]=a[i+1]; printf("\n"); for(i=0;i<n-1;i=i+1) printf("\n a[%d] = %d",i,a[i]); 7
8 else printf("\n Position Not Found"); getch(); // Search the element from array of given position. #include<stdio.h> #include<conio.h> void main() 8
9 int a[50],i,n,x,p; clrscr(); printf("\n Enter array size : "); scanf("%d",&n); printf("enter a[%d] : ",i); scanf("%d",&a[i]); printf("\n Enter position for delete: "); scanf("%d",&p); if(p>0 && p<=n) if((i+1)==p) x=a[i]; printf("\n Element = %d",x); 9
10 else printf("\n Position Not Found"); getch(); // Enter the n element and arrange them on accending order (SORT) #include<stdio.h> #include<conio.h> void main() int a[50],i,n,temp,j; clrscr(); printf("\n Enter array size : "); 10
11 scanf("%d",&n); printf("enter a[%d] : ",i); scanf("%d",&a[i]); for(j=i;j<n;j=j+1) if(a[j]<a[i]) temp=a[i]; a[i]=a[j]; a[j]=temp; printf("\n"); 11
12 printf("\n %d",a[i]); getch(); // Enter two array and marge them #include<stdio.h> #include<conio.h> void main() int a[50],b[50],c[100],n,i,j=0; clrscr(); printf("\n Enter array size : "); scanf("%d",&n); printf("\n Enter Array1\n"); 12
13 printf("enter a[%d] : ",i); scanf("%d",&a[i]); printf("\n Enter Array2\n"); printf("enter b[%d] : ",i); scanf("%d",&b[i]); for(i=0;i<(n+n);i=i+1) if(i<n) c[i]=a[i]; else c[i]=b[j]; 13
14 j=j+1; printf("\n Marg Array"); for(i=0;i<(n+n);i=i+1) printf("\n %d",c[i]); getch(); 14
15 // Enter the one 2d array with size[n x m] matrix and display them. #include<stdio.h> #include<conio.h> void main() int a[10][10],i,j,n,m; clrscr(); printf("\n Enter raw size : "); scanf("%d",&n); printf("\n Enter coloum size : "); scanf("%d",&m); for(j=0;j<m;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); 15
16 printf("\n\n"); for(j=0;j<m;j=j+1) printf(" %d",a[i][j]); printf("\n"); getch(); 16
17 // Enter the two 2d array with size[n x m] and find total them. // And store them in third array #include<stdio.h> #include<conio.h> void main() int a[10][10],b[10][10],c[10][10],i,j,n,m; clrscr(); printf("\n Enter raw size : "); scanf("%d",&n); printf("\n Enter coloum size : "); scanf("%d",&m); printf("\n array1 \n"); for(j=0;j<m;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); 17
18 printf("\n array2 \n"); for(j=0;j<m;j=j+1) printf("enter b[%d][%d] : ",i,j); scanf("%d",&b[i][j]); printf("\ntotal\n"); for(j=0;j<m;j=j+1) c[i][j]=a[i][j]+b[i][j]; printf(" %d",c[i][j]); printf("\n"); getch(); 18
19 // Enter the two 2d array with size[m x m] and find multiplication them. // And store them in third array #include<stdio.h> #include<conio.h> void main() int a[10][10],b[10][10],c[10][10],i,j,k,n,t; 19
20 clrscr(); printf("\n Enter size : "); scanf("%d",&n); printf("\n array1 \n"); for(j=0;j<n;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); printf("\n array2 \n"); for(j=0;j<n;j=j+1) printf("enter b[%d][%d] : ",i,j); scanf("%d",&b[i][j]); 20
21 printf("\nmultiplication\n"); for(j=0;j<n;j=j+1) t=0; for(k=0;k<n;k=k+1) t=t+(a[i][k]*b[k][j]); c[i][j]=t; printf(" %d",c[i][j]); printf("\n"); getch(); 21
22 // Enter the 2d array with size[m x m] and display upper triangle #include<stdio.h> #include<conio.h> void main() int a[10][10],i,j,n; clrscr(); printf("\n Enter size : "); scanf("%d",&n); printf("\n array \n"); 22
23 for(j=0;j<n;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); printf("\n\n"); for(j=0;j<n;j=j+1) printf(" %d",a[i][j]); printf("\n"); printf("\n Upper Trianle\n"); for(j=0;j<n;j=j+1) 23
24 if(i<j) printf(" %d",a[i][j]); else printf(" "); printf("\n"); getch(); 24
25 // Enter the 2d array with size[m x m] and display lower triangle #include<stdio.h> #include<conio.h> void main() int a[10][10],i,j,n; clrscr(); printf("\n Enter size : "); scanf("%d",&n); printf("\n array \n"); 25
26 for(j=0;j<n;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); printf("\n\n"); for(j=0;j<n;j=j+1) printf(" %d",a[i][j]); printf("\n"); printf("\n Lower Trianle\n"); for(j=0;j<n;j=j+1) 26
27 if(i>j) printf(" %d",a[i][j]); else printf(" "); printf("\n"); getch(); 27
28 // Enter the 2d array with size[m x m] and chack it is daigonist or not #include<stdio.h> #include<conio.h> void main() int a[10][10],i,j,n,f; clrscr(); printf("\n Enter size : "); scanf("%d",&n); 28
29 printf("\n array \n"); for(j=0;j<n;j=j+1) printf("enter a[%d][%d] : ",i,j); scanf("%d",&a[i][j]); printf("\n\n"); for(j=0;j<n;j=j+1) printf(" %d",a[i][j]); printf("\n"); printf("\n\n"); 29
30 for(j=0;j<n;j=j+1) if(i==j) if(a[i][j]==1) f=0; else f=1; goto r; else printf(" "); if(a[i][j]==0) f=0; 30
31 else f=1; goto r; r: if(f==0) printf("\n Diagonist Matrix"); else printf("\n Not Diagonist Matrix"); getch(); 31
32 32
Saini Technologies ADVANCED C PROGRAMMING WITH SAINI TECHNOLOGIES. Sushil Kumar Saini Mo.
Saini Technologies ADVANCED C PROGRAMMING WITH SAINI TECHNOLOGIES Sushil Kumar Saini Email: Sushilsaini04@gmail.com Mo. 9896470047 Integer Array int a[]=12,34,54,45,34,34; printf("%d",a[0]); printf(" %d",a[1]);
More informationArrays. Arrays are of 3 types One dimensional array Two dimensional array Multidimensional array
Arrays Array is a collection of similar data types sharing same name or Array is a collection of related data items. Array is a derived data type. Char, float, int etc are fundamental data types used in
More informationSoftware Testing Laboratory Lab Assignments
Problem Statement 01 (Week 01) Software Testing Laboratory Lab Assignments Consider an automated banking application. The user can dial the bank from a personal computer, provide a six-digit password,
More informationIV Year I SEMESTER. Software Testing Lab
IV Year I SEMESTER Software Testing Lab T P C 0 3 2 Lab Assignments Problem Statement 01 Consider an automated banking application. The user can dial the bank from a personal computer, provide a six-digit
More informationClassification s of Data Structures
Linear Data Structures using Sequential organization Classification s of Data Structures Types of Data Structures Arrays Declaration of arrays type arrayname [ arraysize ]; Ex-double balance[10]; Arrays
More informationAlgorithms Lab (NCS 551)
DRONACHARYA GROUP OF INSTITUTIONS, GREATER NOIDA Affiliated to Utter Pradesh Technical University Noida Approved by AICTE Algorithms Lab (NCS 551) SOLUTIONS 1. PROGRAM TO IMPLEMENT INSERTION SORT. #include
More informationTo store the total marks of 100 students an array will be declared as follows,
Chapter 4 ARRAYS LEARNING OBJECTIVES After going through this chapter the reader will be able to declare and use one-dimensional and two-dimensional arrays initialize arrays use subscripts to access individual
More informationDEV BHOOMI INSTITUTE OF TECHNOLOGY
DEV BHOOMI INSTITUTE OF TECHNOLOGY Department of Computer Science and Engineering Year: 1 st Semester:1 st C Programming Lab- LAB MANUAL INDEX S.No. Experiments Software Used 1. To find the sum of individual
More informationBit is the smallest unit of data in a computer. A bit has a single binary value, either 0 or 1. A byte is equal to 8 bits.
What is Bit? Bit is the smallest unit of data in a computer. A bit has a single binary value, either 0 or 1. A byte is equal to 8 bits. What is Program? A set of instructions to carry out a task is called
More informationCS11001/CS11002 Programming and Data Structures (PDS) (Theory: 3-1-0) Introduction to arrays
CS11001/CS11002 Programming and Data Structures (PDS) (Theory: 3-1-0) Introduction to arrays 1 What are Arrays? Arrays are our first example of structured data. Think of a book with pages numbered 1,2,...,400.
More informationDEV BHOOMI INSTITUTE OF TECHNOLOGY
DEV BHOOMI INSTITUTE OF TECHNOLOGY Department of Computer Science and Engineering Year: 2nd Semester: 3rd Data Structures- PCS-303 LAB MANUAL Prepared By: HOD(CSE) DEV BHOOMI
More informationDEV BHOOMI INSTITUTE OF TECHNOLOGY Department of Computer Science and Engineering. Algorithm lab- PCS-553 LAB MANUAL
DEV BHOOMI INSTITUTE OF TECHNOLOGY Department of Computer Science and Engineering Year: 3rd Semester: 5th Algorithm lab- PCS-553 LAB MANUAL Prepared By: HOD (CSE) 1 DEV BHOOMI INSTITUTE OF TECHNOLOGY DEV
More informationDeveloped By: P.Venkateshwarlu, Alphores Womens Degree College, Karimnagar
B.Sc (Computer Science) 1 sem Practical Solutions 1.Program to find biggest in 3 numbers using conditional operators. # include # include int a, b, c, big ; printf("enter three numbers
More informationSingle linked list. Program: #include<stdio.h> #include<conio.h> #include<alloc.h> struct node. int info; struct node *next; void main()
Single linked list Program: #include #include #include struct node int info; struct node *next; ; void main() struct node *s,*start,*prev,*new1,*temp,*temp1,*ptemp; int cho,i,j,x,n,p;
More informationPROGRAMMING IN C LAB MANUAL FOR DIPLOMA IN ECE/EEE
PROGRAMMING IN C LAB MANUAL FOR DIPLOMA IN ECE/EEE 1. Write a C program to perform addition, subtraction, multiplication and division of two numbers. # include # include int a, b,sum,
More informationC Programming Lecture V
C Programming Lecture V Instructor Özgür ZEYDAN http://cevre.beun.edu.tr/ Modular Programming A function in C is a small sub-program that performs a particular task, and supports the concept of modular
More informationLABORATORY MANUAL. (CSE-103F) FCPC Lab
LABORATORY MANUAL (CSE-103F) FCPC Lab Department of Computer Science & Engineering BRCM College of Engineering & Technology Bahal, Haryana Aim: Main aim of this course is to understand and solve logical
More informationQ 1. Attempt any TEN of the following:
Subject Code: 17212 Model Answer Page No: 1 / 26 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given in the model answer scheme. 2) The
More informationFUNCTIONS OMPAL SINGH
FUNCTIONS 1 INTRODUCTION C enables its programmers to break up a program into segments commonly known as functions, each of which can be written more or less independently of the others. Every function
More information1. Simple if statement. 2. if else statement. 3. Nested if else statement. 4. else if ladder 1. Simple if statement
UNIT- II: Control Flow: Statements and Blocks, if, switch statements, Loops: while, do-while, for, break and continue, go to and Labels. Arrays and Strings: Introduction, One- dimensional arrays, Declaring
More informationMAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)
Subject Code: 17212 Model Answer Page No: 1/28 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given in themodel answer scheme. 2) The model
More information//2D TRANSFORMATION TRANSLATION, ROTATING AND SCALING. #include<stdio.h> #include<conio.h> #include<graphics.h> #include<math.h> #include<stdlib.
//2D TRANSFORMATION TRANSLATION, ROTATING AND SCALING #include #include #include #include #include void main() int gd=detect,gm,i,x[10],y[10],a,b,c,d,n,tx,ty,sx,sy,ch;
More informationUnit 1 - Arrays. 1 What is an array? Explain with Example. What are the advantages of using an array?
1 What is an array? Explain with Example. What are the advantages of using an array? An array is a fixed-size sequenced collection of elements of the same data type. An array is derived data type. The
More informationF.E. Sem. II. Structured Programming Approach
F.E. Sem. II Structured Programming Approach Time : 3 Hrs.] Mumbai University Examination Paper Solution - May 14 [Marks : 80 Q.1(a) What do you mean by algorithm? Which points you should consider [4]
More informationMODULE 1. Introduction to Data Structures
MODULE 1 Introduction to Data Structures Data Structure is a way of collecting and organizing data in such a way that we can perform operations on these data in an effective way. Data Structures is about
More information-2017-18 1. a.. b. MS-Paint. Ex.No 1 Windows XP c. 23,, d. MS-Dos DIR /W /P /B /L. Windows Xp, MS-Paint, Dir ; 1. Properties 23 10111 23 27 23 17 2. Display Properties MS-Paint ok 1. Start All program
More informationSorting & Searching. Hours: 10. Marks: 16
Sorting & Searching CONTENTS 2.1 Sorting Techniques 1. Introduction 2. Selection sort 3. Insertion sort 4. Bubble sort 5. Merge sort 6. Radix sort ( Only algorithm ) 7. Shell sort ( Only algorithm ) 8.
More informationContents. Sr. No. Title of the Practical: Page no Signature. Gate. OR gate. EX-OR gate. gate. identifying ODD and EVEN number.
Contents Sr. No. Title of the Practical: Page no Signature 01. To Design and train a perceptron for AND Gate. 02. To design and train a perceptron training for OR gate. 03. To design and train a perceptron
More informationBITS PILANI, DUBAI CAMPUS DUBAI INTERNATIONAL ACADEMIC CITY, DUBAI FIRST SEMESTER
BITS PILANI, DUBAI CAMPUS DUBAI INTERNATIONAL ACADEMIC CITY, DUBAI FIRST SEMESTER 2017-2018 COURSE : COMPUTER PROGRAMMING (CS F111) COMPONENT : Tutorial#4 (SOLUTION) DATE : 09-NOV-2017 Answer 1(a). #include
More informationComputers Programming Course 12. Iulian Năstac
Computers Programming Course 12 Iulian Năstac Recap from previous course Strings in C The character string is one of the most widely used applications that involves vectors. A string in C is an array of
More informationUNIT III ARRAYS AND STRINGS
UNIT III ARRAYS AND STRINGS Arrays Initialization Declaration One dimensional and Two dimensional arrays. String- String operations String Arrays. Simple programs- sorting- searching matrix operations.
More informationUnit 5. Decision Making and Looping. School of Science and Technology INTRODUCTION
INTRODUCTION Decision Making and Looping Unit 5 In the previous lessons we have learned about the programming structure, decision making procedure, how to write statements, as well as different types of
More informationDEV BHOOMI INSTITUTE OF TECHNOLOGY
DEV BHOOMI INSTITUTE OF TECHNOLOGY Department of Computer Science and Engineering Year: 2rd Semester: 3rd CBNST Lab-PCS-302 LAB MANUAL Prepared By: HOD (CSE) DEV BHOOMI INSTITUTE OF TECHNOLOGY Department
More informationWAP 10. WAP 11. WAP 12. WAP 13. WAP 14. WAP 15. WAP 16. WAP 1. : 17. WAP 18. WAP 19. WAP 20. WAP 21. WAP 22. WAP 23. WAP & 24. WAP
Contents 1. WAP to accept the value from the user and exchange the values.... 2 2. WAP to check whether the number is even or odd.... 2 3. WAP to Check Odd or Even Using Conditional Operator... 3 4. WAP
More informationArray. Arijit Mondal. Dept. of Computer Science & Engineering Indian Institute of Technology Patna IIT Patna 1
IIT Patna 1 Array Arijit Mondal Dept. of Computer Science & Engineering Indian Institute of Technology Patna arijit@iitp.ac.in Array IIT Patna 2 Many applications require multiple data items that have
More information/* Polynomial Expressions Using Linked List*/ #include<stdio.h> #include<conio.h> #include <malloc.h> struct node. int num; int coeff;
/* Polynomial Expressions Using Linked List*/ #include #include #include struct node int num; int coeff; struct node *next; ; struct node *start1 = NULL; struct node *start2
More informationBCSE1002: Computer Programming and Problem Solving LAB MANUAL
LABMANUAL BCSE1002: Computer Programming and Problem Solving LAB MANUAL L T P Course Type Semester Offered Academic Year 2018-2019 Slot Class Room Faculty Details: Name Website link Designation School
More informationSubject: Fundamental of Computer Programming 2068
Subject: Fundamental of Computer Programming 2068 1 Write an algorithm and flowchart to determine whether a given integer is odd or even and explain it. Algorithm Step 1: Start Step 2: Read a Step 3: Find
More informationIt is necessary to have a single function main in every C program, along with other functions used/defined by the programmer.
Functions A number of statements grouped into a single logical unit are called a function. The use of function makes programming easier since repeated statements can be grouped into functions. Splitting
More informationKareemNaaz Matrix Divide and Sorting Algorithm
KareemNaaz Matrix Divide and Sorting Algorithm Shaik Kareem Basha* Department of Computer Science and Engineering, HITAM, India Review Article Received date: 18/11/2016 Accepted date: 13/12/2016 Published
More informationLinked List in Data Structure. By Prof. B J Gorad, BECSE, M.Tech CST, PHD(CSE)* Assistant Professor, CSE, SITCOE, Ichalkaranji,Kolhapur, Maharashtra
Linked List in Data Structure By Prof. B J Gorad, BECSE, M.Tech CST, PHD(CSE)* Assistant Professor, CSE, SITCOE, Ichalkaranji,Kolhapur, Maharashtra Linked List Like arrays, Linked List is a linear data
More informationAvailable online through ISSN
International Research Journal of Pure Algebra -4(4), 2014, 509-513 Available online through www.rjpa.info ISSN 2248 9037 A STUDY OF UNBALANCED TRANSPORTATION PROBLEM AND USE OF OBJECT ORIENTED PROGRAMMING
More informationExtraction of Features from 'C' Programs
Extraction of Features from 'C' Programs Vijaykumar Mantri Department of Information Technology B.V.Raju Institute of Technology Ashok Shigli Department of Biomedical Engineering B.V.Raju Institute of
More informationSOFTWARE TESTING LABORATORY. Subject Code: 10ISL68 I.A. Marks: 25 Hours/Week: 03 Exam Hours: 03 Total Hours: 42 Exam Marks: 50
SOFTWARE TESTING LABORATORY Subject Code: 10ISL68 I.A. Marks: 25 Hours/Week: 03 Exam Hours: 03 Total Hours: 42 Exam Marks: 50 1. Design and develop a program in a language of your choice to solve the Triangle
More informationMAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)
WINTER 18 EXAMINATION Subject Name: Data Structure Model wer Subject Code: 17330 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given in
More informationChapter 7 Solved problems
Chapter 7 7.4, Section D 20. The coefficients of a polynomial function are stored in a single-dimensional array. Display its derivative. If the polynomial function is p(x) = a n x n + a n-1 x n-1 + + a
More informationVivekananda College of Engineering & Technology. Data Structures and Applications (15CS33)
Vivekananda College of Engineering & Technology [Sponsored by Vivekananda Vidyavardhaka Sangha, Puttur ] Affiliated to Visvesvaraya Technological University Approved by AICTE New Delhi & Govt of Karnataka
More informationArrays in C. By Mrs. Manisha Kuveskar.
Arrays in C By Mrs. Manisha Kuveskar. C Programming Arrays An array is a collection of data that holds fixed number of values of same type. For example: if you want to store marks of 100 students, you
More informationOverview of Transformations (18 marks) In many applications, changes in orientations, size, and shape are accomplished with
Two Dimensional Transformations In many applications, changes in orientations, size, and shape are accomplished with geometric transformations that alter the coordinate descriptions of objects. Basic geometric
More informationDEPERTMENT OF CIVIL ENGINEERING RAJSHSHI UNIVERSITY OF ENGINEERING & TECHNOLOGY CE 206 NUMERICAL METHODS & COMPUTER PROGRAMMING SESSIONAL
Heaven's Light Is Our Guide DEPERTMENT OF CIVIL ENGINEERING RAJSHSHI UNIVERSITY OF ENGINEERING & TECHNOLOGY CE 206 NUMERICAL METHODS & COMPUTER PROGRAMMING SESSIONAL Submitted by: Name : Md. Abdullah Asad
More informationPrepared By:- Dinesh Sharma Asstt. Professor, CSE & IT Deptt. ITM Gurgaon
Data Structures &Al Algorithms Prepared By:- Dinesh Sharma Asstt. Professor, CSE & IT Deptt. ITM Gurgaon What is Data Structure Data Structure is a logical relationship existing between individual elements
More informationUnit 3 Decision making, Looping and Arrays
Unit 3 Decision making, Looping and Arrays Decision Making During programming, we have a number of situations where we may have to change the order of execution of statements based on certain conditions.
More information/*Tree Traversals*/ #include<stdio.h> #include<conio.h> typedef struct bin { int data; struct bin *left,*right; }node;
/*Tree Traversals*/ #include #include typedef struct bin int data; struct bin *left,*right; node; void insert(node *,node *); void inorder(node *); void preorder(node *); void postorder(node
More informationF.Y. Diploma : Sem. II [CO/CD/CM/CW/IF] Programming in C
F.Y. Diploma : Sem. II [CO/CD/CM/CW/IF] Programming in C Time : 3 Hrs.] Prelim Question Paper Solution [Marks : 70 Q.1 Attempt any FIVE of the following : [10] Q.1 (a) List any four relational operators.
More informationMAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified) MODEL ANSWER
Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given in the model answer scheme. 2) The model answer and the answer written by candidate
More informationMGM S JAWAHARLAL NEHRU ENGINEERING COLLEGE N-6, CIDCO, AURANGABAD LAB MANUALS SUB: COMPUTER LAB-II CLASS: S.E.CIVIL
MGM S JAWAHARLAL NEHRU ENGINEERING COLLEGE N-6, CIDCO, AURANGABAD LAB MANUALS (Procedure for conduction of Practical/Term Work) SUB: COMPUTER LAB-II CLASS: S.E.CIVIL Prepared by Ms.V.S.Pradhan Lab In charge
More informationF.E. Sem - 2 CBCGS SPA MAY 17
F.E. Sem 2 CBCGS SPA MAY 17 Q.1.a.) Convert 0010 0100 0010 1101 from base 2 to decimal. Convert 134 from base 10 to hexadecimal. Write steps for conversion. Ans: Binary to decimal: The steps to be followed
More informationWhat is recursion. WAP to find sum of n natural numbers using recursion (5)
DEC 2014 Q1 a What is recursion. WAP to find sum of n natural numbers using recursion (5) Recursion is a phenomenon in which a function calls itself. A function which calls itself is called recursive function.
More information"'"' .;, b) F or ( c = l ; c <= 10,"' c++ ) X { JJ. ~. Computer Programming I COME Midterm Examination. Fall November 2016
Group B ~. Computer Programming I COME 103 - Midterm Examination B Fall 2016 21 November 2016 1. Identify and correct the errors in each of the following statements. (Note: There may be more than one error.)
More informationPrepared by: Shraddha Modi
Prepared by: Shraddha Modi Introduction In looping, a sequence of statements are executed until some conditions for termination of the loop are satisfied. A program loop consist of two segments Body of
More informationAn array is a collection of similar elements that is all the elements in an array should have same data type. This means that an array can store
An array is a collection of similar elements that is all the elements in an array should have same data type. This means that an array can store either all integers, all floating point numbers, all characters,
More informationColumns A[0] A[0][0] = 20 A[0][1] = 30
UNIT Arrays and Strings Part A (mark questions). What is an array? (or) Define array. An array is a collection of same data type elements All elements are stored in continuous locations Array index always
More information'C' Programming Language
F.Y. Diploma : Sem. II [DE/EJ/ET/EN/EX] 'C' Programming Language Time: 3 Hrs.] Prelim Question Paper Solution [Marks : 70 Q.1 Attempt any FIVE of the following : [10] Q.1(a) Define pointer. Write syntax
More information& Technology. G) Functions. void. Argument2, Example: (Argument1, Syllabus for 1. 1 What. has a unique. 2) Function name. passed to.
Computer Programming and Utilization (CPU) 110003 G) Functions 1 What is user defined function? Explain with example. Define the syntax of function in C. A function is a block of code that performs a specific
More informationVivekananda College of Engineering & Technology. Data Structures and Applications
Vivekananda College of Engineering & Technology [Sponsored by Vivekananda Vidyavardhaka Sangha, Puttur ] Affiliated to Visvesvaraya Technological University Approved by AICTE, New Delhi & Govt. of Karnataka
More informationUnit 8. Structures and Unions. School of Science and Technology INTRODUCTION
INTRODUCTION Structures and Unions Unit 8 In the previous unit 7 we have studied about C functions and their declarations, definitions, initializations. Also we have learned importance of local and global
More informationSELECTION STATEMENTS:
UNIT-2 STATEMENTS A statement is a part of your program that can be executed. That is, a statement specifies an action. Statements generally contain expressions and end with a semicolon. Statements that
More informationSRI VIDYA COLLEGE OF ENGINEERING & TECHNOLOGY, VIRUDHUNAGAR Department of CSE & IT Internal Test I
SRI VIDYA COLLEGE OF ENGINEERING & TECHNOLOGY, VIRUDHUNAGAR Department of CSE & IT Internal Test I Year & Sem: I B.E (CSE) & II Date of Exam: 21/02/2015 Subject Code & Name: CS6202 & Programming & Data
More informationCSE101-Lec#18. Multidimensional Arrays Application of arrays. Created By: Amanpreet Kaur & Sanjeev Kumar SME (CSE) LPU. LPU CSE101 C Programming
CSE101-Lec#18 Multidimensional Arrays Application of arrays Created By: Amanpreet Kaur & Sanjeev Kumar SME (CSE) LPU Outline Defining and processing 1D array 2D array Applications of arrays 1-D array A
More informationUnit 3 Functions. 1 What is user defined function? Explain with example. Define the syntax of function in C.
1 What is user defined function? Explain with example. Define the syntax of function in C. A function is a block of code that performs a specific task. The functions which are created by programmer are
More informationINDEX BUBBLE SORT INSERTION SORT SELECTION SORT PATTREN MATCHING LINEAR SEARCH BINARY SEARCH QUICK SORT MERGE SORT STACK OPERATION USING ARRAY
INDEX S.No. Date Title Page No. Teacher s Sign 1. BUBBLE SORT 2. INSERTION SORT 3. SELECTION SORT 4. PATTREN MATCHING 5. LINEAR SEARCH 6. BINARY SEARCH 7. QUICK SORT 8. MERGE SORT 9. STACK OPERATION USING
More informationSOFTWARE TESTING LABORATORY. I.AMarks:20 Hours/Week: 03 ExamHours: 3 Total Hours: 40 Exam Marks: 80 Number of Lecture Hours/Week: 01I + 02P
SOFTWARE TESTING LABORATORY Subject Code: 15ISL67 I.AMarks:20 Hours/Week: 03 ExamHours: 3 Total Hours: 40 Exam Marks: 80 Number of Lecture Hours/Week: 01I + 02P 1. Design and develop a program in a language
More informationProgramming in C Lab
Programming in C Lab 1a. Write a program to find biggest number among given 3 numbers. ALGORITHM Step 1 : Start Start 2 : Input a, b, c Start 3 : if a > b goto step 4, otherwise goto step 5 Start 4 : if
More informationProgramming and Data Structures Mid-Semester - Solutions to Sample Questions Dept. of Computer Science and Engg. IIT Kharagpur Spring
Programming and Data Structures Mid-Semester - s to Sample Questions Dept. of Computer Science and Engg. IIT Kharagpur Spring 2015-16 February 15, 2016 1. Tick the correct options. (a) Consider the following
More informationDEV BHOOMI INSTITUE OF TECHNOLOGY DEHRADUN Department Of Computer Application. Design and Analysis of Algorithms Lab MCA-302
DEV BHOOMI INSTITUE OF TECHNOLOGY DEHRADUN Department Of Computer Application Design and Analysis of Algorithms Lab MCA-302 1 INDEX S.No. PRACTICAL NAME DATE PAGE NO. SIGNATURE 1. Write a Program to Implement
More informationInternational Journal of Mathematics & Computing. Research Article
www.advancejournals.org Open Access Scientific Publisher Research Article C/C++ PROGRAM: DETERMINATION OF ENERGY BAND GAP FROM UV-VISIBLE SPECTROGRAPH RESULTS ABSTRACT Rajivgandhi S 1, Dinesh Kumar A 2,
More informationMAHARASHTRASTATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)
Subject Code: 17330 Model Answer Page 1/ 22 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given in the model answer scheme. 2) The model
More information/* Area and circumference of a circle */ /*celsius to fahrenheit*/
/* Area and circumference of a circle */ #include #include #define pi 3.14 int radius; float area, circum; printf("\nenter radius of the circle : "); scanf("%d",&radius); area = pi
More informationUIC. C Programming Primer. Bharathidasan University
C Programming Primer UIC C Programming Primer Bharathidasan University Contents Getting Started 02 Basic Concepts. 02 Variables, Data types and Constants...03 Control Statements and Loops 05 Expressions
More informationAIM:- To write a C program to create a singly linked list implementation.
SINGLY LINKED LIST AIM:- To write a C program to create a singly linked list implementation. ALGORITHM:- 1. Start the program. 2. Get the choice from the user. 3. If the choice is to add records, get the
More informationCase Control Structure. Rab Nawaz Jadoon DCS. Assistant Professor. Department of Computer Science. COMSATS IIT, Abbottabad Pakistan
Case Control Structure DCS COMSATS Institute of Information Technology Rab Nawaz Jadoon Assistant Professor COMSATS IIT, Abbottabad Pakistan Introduction to Computer Programming (ICP) Decision control
More informationGE Computer Practices Lab
GE6161 - Computer Practices Lab Manual ( First semester B.E/B.Tech. Students for the Academic Year 2015-16 ) VALLIAMMAI ENGINEERING COLLEGE SRM NAGAR, KATTANKULATHUR 603 203 Prepared by T. Rajasekaran,
More information4(a) ADDITION OF TWO NUMBERS. Program:
4(a) ADDITION OF TWO NUMBERS int a,b,c: printf( enter the elements a and b ); scanf( %d%d,&a,&b); c=a+b; printf( sum of the elements is%d,c); Output: Enter the elements a and b: 4 5 Sum of the elements
More informationB.L.D.E.A s Vachana Pitamaha Dr. P. G. Halakatti College of Engineering and Technology, Vijayapur
B.L.D.E.A s Vachana Pitamaha Dr. P. G. Halakatti College of Engineering and Technology, Vijayapur-586103. Department of Computer Science and Engineering Lab Manual Subject : Computer Programming Laboratory
More informationCourse Code : MCS-011 Course Title : Problem Solving and Programming Assignment Number : MCA(1)/011/Assign/13 Maximum Marks : 100 Weightage : 25%
For more IGNOU Solved Assignments visit www.ignouhelp.in Get Daily Updates by Facebook: https://www.facebook.com/ignouhelp.in Course Code : MCS011 Course Title : Problem Solving and Programming Assignment
More information1) Write a C Program to check whether given year is Leap year or not. AIM: A C Program to check whether given year is Leap year or not.
1) Write a C Program to check whether given year is Leap year or not. AIM: A C Program to check whether given year is Leap year or not. #include int year; printf("enter a year:"); scanf("%d",&year);
More informationMAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)
WINTER 17 EXAMINATION Subject Name: Data Structure Using C Model Answer Subject Code: 17330 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as
More informationChapter 8 Character Arrays and Strings
Chapter 8 Character Arrays and Strings INTRODUCTION A string is a sequence of characters that is treated as a single data item. String constant: String constant example. \ String constant example.\ \ includes
More informationTHE BAPATLA ENGINEERING COLLEGE:: BAPATLA DEPARTMENT OF MCA. Subject name: C programing Lab. Subject code: MCA 107. LAB manual of c programing lab
THE BAPATLA ENGINEERING COLLEGE:: BAPATLA DEPARTMENT OF MCA Subject name: C programing Lab Subject code: MCA 107 LAB manual of c programing lab 1. Write a C program for calculating compound interest. #include
More informationUNDERSTANDING THE COMPUTER S MEMORY
POINTERS UNDERSTANDING THE COMPUTER S MEMORY Every computer has a primary memory. All our data and programs need to be placed in the primary memory for execution. The primary memory or RAM (Random Access
More informationCSE202- Lec#6. (Operations on CSE202 C++ Programming
Arrays CSE202- Lec#6 (Operations on Arrays) Outline To declare an array To initialize an array Operations on array Introduction Arrays Collection of related data items of same data type. Static entity
More informationLab 10: Disk Scheduling Algorithms
1. Objective Lab 10: Disk Scheduling Algorithms Understand Disk Scheduling Algorithm and read its code for SSTF, SCAN, CSCAN in C, 2. Syllabus try to write other kinds of disk scheduling algorithms such
More informationEx. No. 3 C PROGRAMMING
Ex. No. 3 C PROGRAMMING C is a powerful, portable and elegantly structured programming language. It combines features of a high-level language with the elements of an assembler and therefore, suitable
More informationLAB MANUAL FOR DATA STRUCTURE USING C
LAB MANUAL FOR DATA STRUCTURE USING C Prepared by, Sunita Debbarma Lecturer Computer Science & Technology Department DEPARTMENT OF COMPUTER SCIENCE & TECHNOLOGY WOMEN S POLYTECHNIC HAPANIA, AGARTALA, TRIPURA
More informationComputer Programming. C Array is a collection of data belongings to the same data type. data_type array_name[array_size];
Arrays An array is a collection of two or more adjacent memory cells, called array elements. Array is derived data type that is used to represent collection of data items. C Array is a collection of data
More informationPROGRAM 1 AIM: Write a program to find the number of vertices, even vertices, odd vertices and the number of edges in a graph.
PROGRAM 1 AIM: Write a program to find the number of vertices, even vertices, odd vertices and the number of edges in a graph. CODE: #include using namespace std; #include #define MAX
More informationConcepts & Practice Computer Science N. Mohan., MCA., B.Ed Std: 11 Two, Three marks & Five Marks SSV, Sivagiri.
Concepts & Practice Computer Science N. Mohan., MCA., B.Ed Std: 11 Two, Three marks & Five Marks SSV, Sivagiri TWO MARKS 1. Define Computer. 2. Define Algorithm? 3. What are the parts of the computer?
More informationMAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)
WINTER 18 EXAMINATION Subject Name: Data Structure using C Model wer Subject Code: 22317 Important Instructions to examiners: 1) The answers should be examined by key words and not as word-to-word as given
More informationCSE101-lec#19. Array searching and sorting techniques. Created By: Amanpreet Kaur & Sanjeev Kumar SME (CSE) LPU. LPU CSE101 C Programming
CSE101-lec#19 Array searching and sorting techniques Created By: Amanpreet Kaur & Sanjeev Kumar SME (CSE) LPU Outline Introduction Linear search Binary search Bubble sort Introduction The process of finding
More informationC Exercises. Ben Vandiver February 28, 2003
C Exercises Ben Vandiver February 28, 2003 1 General Information These exercises are intended for you to practice on. Since they won t be graded, they are to help you practice the types of things you will
More information