CS201 Introduction to Programming Solved Subjective For Midterm ...
Recommend Documents
MCQs For Midterm Exam Preparation. CS201. 1 - Application Softwares are use
to. 1. Type letters. 2. Control computer hardware. 3. Solve end user problems. 4.
CS201 - Introduction to Programming Midterm Paper(1) 2010. Question No.: 1 (
M a r k s: 1 ). Compiler is a. System software. Application Software. Driver. Editor.
Share your feedback/comments at [email protected] to improve file|| Back to TOP || File Version v1.5.23 published for M
QUESTION: WHAT IS A TRANCE DENTAL EQUATION? ... Q. WHAT IS THE DIFFERENCE BETWEEN OPEN AND BRACKETING METHOD? ...... Ope
WHEN THE NEWTON'S BACKWARD DIFFERENCE INTERPOLATION FORMULA ...... trigonometric and exponential function or combination
1. CS201 Midterm Test. Name: SSN: 1. (7 marks) The relation R is a relation on
the set {a, b, c, d}. Which one (ones) is (are) equivalence relation(s)? a) R={(a, a),
...
A control engineer, N. Minorsky, designed an innovative ship steering system in
... V. (a) (4 points) Determine K so that overshoot is 7%. (b) (2 points) What is the
...
Top Funny Site (SantaBanta, Punjabi Totay, Bankay Mian etc). 7. Top Video Site (
YouTube, ... Funny Videos:-. Santa Banta (Funny Sardar Jokes Videos).
Midterm Exam, Total = 100 Points. Please write neatly and show as much of your
work as possible for partial credit. Scan through all problems first, and attack ...
Who collected Quranic verses in one place: a) Hazrat Umar (RA) b) Hazrat
Abdullah ibne Abbas (RA) c) Hazrat Abdullah ibne Masud (RA) d) Hazrat Usman
(RA).
What is the difference between Alphanumeric and Decimal System? Decimal system is a numbering system that uses ten digit
What is the difference between Alphanumeric and Decimal System? Decimal system is a numbering system that uses ten digit
Description: Object-oriented paradigm for programming-in-the-large in Java;
writing ... Chapters from Liang's Introduction to Java Programming, 9th Edition.
these tools elevates a programmer to a system programmer, often considered ....
The typical Windows computer operator just wants to run applications. It.
The em- phasis is on learning how to program, rather than on the theory of logic
.... to solve practical problems in computer science and artificial intelligence. .....
Two free variables also match, because they could be instantiated with the same
Look at a game console: PS2 ... To technophiles, this is a PS2 .... texture? Source
: http://playstation2-linux.com/download/p2lsd/ps2_normalmapping.pdf ...
Programmers tell computers what to do. Computers ..... Scripting languages can
be excellent for beginners: they tend to be easier to learn, and they insulate you
from some of the ..... PDF files, or a plug-in that lets you view Quicktime movies.
LiveLab is a programming course assessment and management system. Students can .... B MySQL Tutorial. C Oracle Tutorial.
Malware That Propagates. • Virus = code that propagates (replicates) across
systems with user intervention. • Worm = code that self-propagates/replicates.
Eclipse. 2. Install and configure Android SDK plugin in Eclipse. 1. Install Android
Development Tools. (ADT) plugin https:dl-ssl.google.comandroideclipse.
problem-driven complete revision new problems early console input hand trace box multidimensional arrays. Sudoku problem
... a program, the yellow- shaded boxes show the memory content after each
Python state- .... 5.10 Program caesar cipher3.py. . . . . . . . . . . . . . . . . . . 74 ..... an
excellent series of Unix tutorials for beginners is available at http://ww
Do – Loop Until. Introduction to VBA programming - (c) 2009 Dario Bonino .....
Write a program to check if a word is palindrome,. i.e. if it is equal when read from
...
CS201 Introduction to Programming Solved Subjective For Midterm ...
Virtualians Social Network www.virtualians.pk. Prepared by: Irfan Khan. CS201
Introduction to Programming Solved. Subjective For Midterm Exam Preparation.
CS101 Introduction of computing
CS201 Introduction to Programming Solved Subjective For Midterm Exam Preparation Question No: 17 ( Marks: 2 ) What is the difference between switch statement and if statement. Answer: 1.if statement is used when we have to check two conditions while switch is a multi conditional control statement 2. SWITCH statement can be executed with all cases if the “break” statement is not used whereas IF statement has to be true to be executed further.
Question No: 18 ( Marks: 2 ) Why we close a file after use? Answer: To save our data stored on file. Also this process makes our program fast and reliable. OR You have finished with it. This is particularly important if you are writing to the file. The operating system does not switch on the disk drive to write just a single character to the disk, rather it waits until it has a load to write and then writes the lot s in one go. http://www2.sis.pitt.edu/ir/KS/Data/RMiles/c12.html
Question No: 19 ( Marks: 2 ) A two-dimensional array has 3 rows and 4 columns. Write down the syntax to initialize first element of all three rows of two-dimensional array with value 2. Answer: int matrix[0][0]=2 int matrix[1][0]=2 int matrix[2][0]=2 Question No: 20 ( Marks: 3 ) Identify the errors in the following code segment and give the reason of errors. main(){ int x = 10 const int *ptr = &x ; *ptr = 5 ; } Answer: Int x=10….No ending semicolon. *ptr=5... Declaring a pointer to constant integer. You cannot use this pointer to change the value being pointed to. Question No: 21 ( Marks: 3 ) Can you use an assignment operator to assign the value of one C-string to another? Answer: Yes we can assign the one value of C-string to another using assignment operator. We can assign the value of one string to another string through this method. A[0]=B[0] A[1]=B[2] A[3]=B[3] And we can assign the whole string to another C string using Assignment operator by using loops. Question No: 22 ( Marks: 5 ) Why binary search algorithm is more efficient than the linear search algorithm?
Virtualians Social Network
www.virtualians.pk
Prepared by: Irfan Khan
CS101 Introduction of computing Answer: (page118) Binary search algorithm is more efficient than liner algorithm because the arrays are sorted in asending or desending order and we use “devide and conqrer” technique. In binary search each iteration reduces the search by the factor of two but in the linear we have the same number of searches as we have the number of elements.e.g,if we have array of 1000 elements the linear search will take 1000 iterations however binary search will take max 10. Question No: 23 ( Marks: 5 ) Write down the output of the code given below : Hint: Size of char is 1 byte Size of int is 2 byte Size of float is 4 byte #include union mytypes_t { char c; int i; float f; } mytypes; int main(){ mytypes.c = 'H'; mytypes.i = 15; cout