0% found this document useful (0 votes)
17 views

Computer Notes 12th

The document is a comprehensive outline of a Computer Science curriculum for 2nd-year students, covering various chapters related to data basics, database concepts, normalization, MS Access, and programming in C. Each chapter includes short and long questions that assess understanding of key concepts such as data processing, database design, data integrity, and programming fundamentals. The content is structured to facilitate learning and evaluation of essential computer science topics.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

Computer Notes 12th

The document is a comprehensive outline of a Computer Science curriculum for 2nd-year students, covering various chapters related to data basics, database concepts, normalization, MS Access, and programming in C. Each chapter includes short and long questions that assess understanding of key concepts such as data processing, database design, data integrity, and programming fundamentals. The content is structured to facilitate learning and evaluation of essential computer science topics.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

COMPUTER SCIENCE (2ND YEAR)

CHAPTER # 1
Data Basics

Short Question: Long Question:

Q1: Differentiate btw data & information. Q1: Define data processing. What activities are
Q2: What is Data? involved in data processing? Discuss in detail
Q3: What is information? Q2: What is file processing system? Discuss
Q4: what do you know about data processing? three problems/ disadvantages of traditional file
Q5: List different activities involved in data processing. processing.
Q6: Define Data Capturing. Q3: Describe the file by usage and functional
Q7: Data Manipulation. point of view in detail?
Q8: Differentiate btw master file & transaction file. Q4: What is file? Explain file by Storage point of
Q9: Write down the name of file from usage point of view. view.
Q10: What is difference btw program file & data file? Q5: Define Database. Write down four major
Q11: list file types from storage point of view. component of database system in detail.
Q12: What is meant by file organization?
Q6: Define database. Discuss the objective of
Q13: how data is stored in files?
database system.
Q14: Define database.
Q7: Define database model. Describe the
Q13: what do you mean by data independence?
different Database Model.
Q14: Write three examples of database system.
Q15: What is difference btw file and database? Q8: Write down the objective of DBMS.
Q16: What is basic purpose of data integrity? Q9: Describe the feature of Database
Q17: Define data integration. management system.
Q18: Why hierarchical Model Considered like an
Q10: Advantages and Dis Advantages of DBMS.
organization chart?
Q19: What is Database Model?
Q20: list different types of database Model.
Q21: what is basic difference between hierarchical and
network model?
Q22: Differentiate btw database and DBMS.
Q23: Define DBMS.
Q24: what is meant by data redundancy?
Q25: why is report generator used in database?
Q26: What is data dictionary?
Q27: Define DDL
Q28: Define DML.
Q29: Define DCL.
Q30: Define SQL
Q31: Define Indexed Sequential File.
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 2
Basic Concept and Terminology of Database

Short Question: Long Question:

Q1: Define data handling in file management system. Q1: What is FMS? Write down the Details of
Q2: Define the term table/relation. Field , Record , File .
Q3: Describe any two properties of table/relation. Q2 What is table or relation? Write down the
Q4: What is an attribute? Give example. properties of relation.
Q5: Define file, record and field.
Q3: What is key? Describe the different types
Q6: Define Entity?
of keys used in database.
Q7: What is user or End user?
Q8: State the purpose of index file.
Q9: What is View? Purpose of using Views? How to Write
Views?
Q10: Write the responsibilities of DBA in database system.
Q11: Write the responsibilities of Data administrator (DA).
Q12: Write the purpose of indexes.
Q13: Define primary key.
Q14: Define secondary key.
Q15: Define foreign key.
Q16: write down the Function of Key.
Q17: Write a note on composite key.
Q18: Define Alternate key.
Q19: what is candidate key?
Q20: Define Sort Key.
Q21: Define Data Manipulation in DBMS.
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 3
Database Design Process

Short Question: Long Question:

Q1: What is the purpose of feasibility study? Q1: Discuss Different steps involved in Analysis
Q2: How is data analysis performed? stage while designing data base.
Q3: which activities are involved in data analysis? Q2: What is data modeling? Explain different
Q4: What is project planning? ingredients of data modeling.
Q5: Define entity.
Q3: What is ER diagram? Give an example of ER
Q6: what is attribute?
diagram.
Q7: Define the term cardinality of relation.
Q8: Define Modality. Q4: what is database design? Briefly explain
Q9: How can you define relation in ER diagram? the database design process with the help of
Q10: Differentiate between cardinality & Modality. diagram.
Q11: list down different type of relationship. Q5: Write down the different components of a
Q12: define data modeling. logical database design model.
Q13: What is ER diagram?
Q14: Define implementation in database. Q6: Explain physical database design process.
Q15: what is purpose of logical database design? Q7: Briefly describe basic data distribution
Q16: What is Physical database design? strategies?
Q17: Write down the different phases of logical database
design.
Q18: List any four component of physical database design.
Q19: List down the data distribution strategies.
Q20: Define integrity constraints.
Q21: what do you know by file organization?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 4
Data integrity and Normalization

Short Question: Long Question:

Q1: What is Data integrity? Q1: What is data integrity? Explain its types.
Q2: What is entity integrity? How to attain it? Q2 : What type of a problem may exist in a
Q3: Define Referential integrity. How to attain it? relation before Normalization?
Q4: what is meant by Normalization?
Q5: Define full Functional dependency. Q3 : Define Data base Anomalies and their
types.
Q6: What is transitive dependency?
Q7: What is repeating group? Q4: What is normalization? What is first
Q8: what is 1NF? normal form? Explain in detail.
Q9: Define second normal form.
Q5: What is normalization? Explain second
Q10: When is the relation is in first normal form?
normal form with example.
Q11: Write down the condition for a table to be in 2NF.
Q12: What is Partial dependency? Q6: Define normalization? Explain the third
Q13: What is third normal form? normal form.
Q14: What type of anomalies occurred due to transitive
dependency?
Q15: Define synonyms.
Q16: Define Homonym.
Q17: What is meant by redundancy?
Q18: What are Mutually Exclusive Data?
Q19: What are database anomalies?
Q20: Define insertion anomaly.
Q21: What is deletion anomaly?
Q22: what is modification / update anomaly?
Q23: What is Transitive dependency?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 5
Introduction to MS Access

Short Question: Long Question:

Q1: What is MS Access?


Q2: State the use of MS Access. Q1: what is MS Access? Write its Advantages.
Q3: What is RDBMS?
Q4: Write down the advantages of RDMBS. Q2: What are advantages of using a Microsoft
Q5: What is database wizard? Access IDE?
Q6: What is Toolbar in MS-Access? Q3: Describe different parts of the application
Q7: What is Title bar in MS-Access? window of MS Access.
Q8: What is main idea of Scroll Bar and Status Bar?
Q4: Describe the Data Base window in MS
Q9: Differentiate btw Toolbar and Menu bar?
Access.
Q10: Describe any two bar of MS-Access application
window. Q5: Explain the following terms
Q11: Define Database Objects.
1- Form 2-Report 3- Table 4- Query
Q12: Why Table object of Database is most important?
Q13: What is report?
Q14: Write down the uses of report.
Q15: differentiate btw form and report.
Q16: Differentiate btw table and query.
Q17: Define IDE.
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 6
Table & Query

Short Question: Long Question:

Q1: What is meant by degree of relation? Q1: How would you define table? Also write
Q2: What is meant by cardinality of relation? Characteristics of table.
Q3: How many views in Access? Q2: What are two Table Views Available in MS
Q4: Define field. Access? How you can switch between them
Q5: Write down two characteristics of table.
Q3: What are field Properties? Explain at least
Q6: List three methods for creating table?
three field properties with an example.
Q7: Describe the use of design view in MS-Access.
Q8: Define Datasheet view. Q4: Explain the different Types of data types
Q9: How database is created in design view? available in MS- Access.
Q10: List out different data type available in MS-Access.
Q5: Describe different methods of modifying
Q11: What is Primary key? tables.
Q12: Define datasheet view.
Q13: How database is created in design view? Q6: What is filter? Discuss different types of
Q14: What is referential integrity? filters in MS-Access.
Q15: Write use of OLE objects in MS-Access. Q7: What is Query? Discuss different types of
Q16: What is use of input mask? queries. Also explain use of Wild Cards in
Q17: write two differences btw relationship and join. Query.
Q18: What is meant by filter?
Q8: What is Query? Write advantages of
Q19: what is difference btw sorting & filters?
Query.
Q20: Define query.
Q21: Define parametric query.
Q22: How record is stored in a query?
Q23: Name different types of queries use in database.
Q24: What do you know about select query?
Q23: What is difference btw cross tab and parametric query?
Q24: What is query wizard?
Q25: Write down some uses of query. Or advantages.
Q26: Differentiate between update and append query.
Q27: What is use of Wild Card?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 7
MS-Access Forms & Reports

Short Question: Long Question:

Q1: What is form? Q1: What is form? Explain its uses and
Q2: What is Columnar Form? advantage
Q3: Write a note on Tabular form? Q2: Discuss different option for editing form in
Q4: What do you know about datasheet form? MS Access.
Q5: Why form object of database is used?
Q3: What is report? Briefly explain its Types
Q6: How is Form constructed?
and advantages
Q7: Write down some advantages of form?
Q8: List different types of forms in MS-Access.
Q9: What is sub form?
Q10: What are the uses of List Box?
Q11: Describe Radio Button?
Q12: Differentiate btw form and sub form?
Q13: What is Check Box?
Q14: How is combo box used?
Q15: List any five Buttons available on Access database
window?
Q16: Difference between combo box and list box.
Q17: What is difference btw form and reports?
Q18: Write down some uses of reports.
Q19: How is report created by using wizard?
Q20: Define Report.
Q21: List any two advantages of using reports.
Q22: Define conditional Formatting?
Q23: What is linking?
Q24: Write the use of switchboard?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 8
Getting started with C

Short Question: Long Question:

Q1: Differentiate btw Structured and Unstructured Q1: What is programming language? Explain its
Languages. types.
Q2: Differentiate btw source code and object code. Write common characteristics of C Language
Q3: Give any four examples of High-level Languages. and all high-level program languages.Q2: How
Q4: What do you mean by machine independence? would you define High level language?
Q5: Why source code cannot be executed directly?
Q6: What is assembly language? Q3: Write the detail Steps of Writing a program
in C language for Execution. Explain it with
Q7: Define low level language.
Diagram.
Q8: Define Program.
Q9: write down the use of Turbo C++ compiler. Q4: What is the basic structure of c program?
Q10: Define IDE of turbo C++. Discuss in detail.
Q11: Why main Function is important in every C language
Q5: What is debugging? Explain all different
Program.
types of errors uncovered by debugging
Q12: What is the usage of loader.
Process?
Q13: Define linker
OR Q6 : What is Difference between Structured and
How executable file is created? Un Structured Programming Languages.
Q14: Write shortcut keys for Compiling and Running
program in C.
Q15: Write shortcut key for saving the C program.
Q16: what is difference btw linker and loader?
Q17: Write the use of define directive.
Q18: distinguish btw compiler and interpreter.
Q19: Define header file.
Q20: What is the purpose of # sign?
Q21: Define main () function.
Q22: write down the use of delimiter.
Q23: Write two uses of preprocessor directives.
Q24: Define statement terminator.
Q25: Define include directive.
Q26: What is constant Macro?
Q27: What is C-statement?
Q28: Why C is known as Strongly typed language.?
Q29: Define bug and debugging.
Q30: What is Syntax error?
Q31: Define logical error.
Q32: Which type of error is difficult to trace and why?
Q33: What do you know about run time error?
Q34: What is the purpose of compiler?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 9 Elements of C
Short Question: Q30: Trace output
printf(“Pakistan \t is \n my\t homeland”);
Q1: What is identifier? Define Types. Q31: Compare unary and binary operator.
Q2: Difference between are and “area” in C. Q32: What will be the value of following code
Q3: Define Type Castting? printf(“%d”, ‘a’+’b’);
Q4: Define keywords in C-Language. Q33: Rewrite the statement x-=2 without
Q5: Give two examples of standard identifier. compound assignment operator.
Q6: Write the legal character for an identifier. Q34: What is use of increment operator?
Q7: Write C statement to declare integer variable x and Q35: rewrite the expression n++ without using
assign any value to x. increment operator.
Q8: What is garbage Value? Q36: What is prefix and postfix increment
Q9: Differentiate btw declaring and defining a variable. operator?
Q10: What is variable? Q37: What is decrement operator?
Q11: what is mean of declaring a variable? Q38: What is meant by operator precedence?
Q12:]Write down the C-Statement that initialize character Q39: Determine the output of following codes
ch1,ch2,ch3 in one line. a) Int m,n,k;
Q13: What is meant by initializing a variable? m= 15, n=20;
Q14: Trace the error from following code k= m+n;
printf(“k=%d”, --k);
Int room #;
b) Int x=10;
printf(“%d”,5)
y=++x;
Q15: Differentiate btw character constant and string.
x=--y;
Q16: Write down Three rules for naming a variable.
printf(“%d”, y);
Q17: What is Constant? c) Int n,a,b;
Q18: Write a note on long double type. n= 400;
Q19: List any two data type in C Language. a=n%100;
Q20: Find error b=n/10;
Int a=5 printf(“Result=%d %d”a,b);
Int double= 20; Q40: What will the value of x and y.
printf(“Result = %d”, double) Int x=7;
Q21: Determine the output.
Y=x++;
Int x=7;
Q41: Define expression.
Int y=3;
printf( “%d and %d”, x/y, x%y); Q42: What are comments?
Q22: Predict the output of following code. Q43: Define arithmetic expression.
Int x=13; Q44: Define Lvalue and Rvalue.
Int y=3; Q45: What will be the value of x if
printf(“%d and %d”, x/y, y/x, x%y); X=1+2%3-3;
Q23: Give Examples of Valid and invalid Variables names. LONG Question:
Q24: Write a note on arithmetic operator.
Q25: What is relational operator? Q1 : Define Identifiers.
Q26: Write a note on assignment operator. Q 2 : Write down the Rules for naming
Q27: Define a logical operator in C-Language.
Variable in C
Q28: Define compound condition.
Q29: what is Associativity of Operators? Q3 : Define Operators.
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 10
Input and output

Short Question: d) float p= 79.23;


printf(“%10.1f”, p);
Q1: What is printf f function also write its syntax? e) int a,b,c;
Q2: What is standard input? a=3;
Q3: Write the name Input function in C-Language. b=a++;
Q4: Write a note on standard output. c=++a;
Q5: Write a single printf statement that show-> printf(“%d%d%d”, a, b, c);
C:\My document Q26: Trace error.
Q6: Define clrscr(). Int x;
Q7: List four format specifier used in C-language. scanf(“%d”, x);
Q8: What is Format specifier?
Q9: Write a C-statement that output Two Values in two
floating point variable a and b.
Q10: Write down the purpose of %c and %e format specifier. LONG Question:
Q11: What is meant by field width specifier?
Q12: How can you specify the field width specifier of integer? Q1: Explain the printf() function with
Q13: How can you specify the field width specifier of floating example.
point?
Q2: Write a note on scanf() function in detail
Q14: Why format specifiers are important to be specified in
I/O operation? with example.
Q15: What is escape sequence? Q3: Explain format Specifiers in Details.
Q16: Write down the name of four escape sequences.
Q17: Discuss the role of \n and \t Q4 : Explain Escape Sequence In Detail.
Q18: discuss the role of\b.
Q19: Why & operator is used in scanf() function?
Q20: What is the use of scanf(). Write its syntax?
Q21: What is format string in scanf function?
Q22: List two names of function to get character input.
Q23: Write difference btw getch() and getche() functions.
Q24: What does happen if & sign is missing in scanf()
function.
Q25: Determine the Output.
a) Int x=0, y=5, z=4;
x=x+y*2;
y=x+y/2;
prtintf(“%d%d”, x,y);
b) Void main()
{ printf(“555 it”):
printf(“999”):
printf(“In 444”); }
c) float p=3.1234;
printf(“%15.2f”, p);
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 11
Decision Construct
Short Question: b) in x=1, y=3, z=3 ;
Q1: What is control structure? if ( (x==y) || (y==z) ||(z==2) )
Q2: How instructions are executed in sequence structure? printf(“Yes”);
Q3: What is selection statement? else
Q4: What is the limitations of simple if statement? printf(“No”);
Q5: write the output of following code c) if ( 2==4 )
If (50<20) printf(“Punjab”);
printf(“ABC”); else
printf(“DEF”); printf(“KPK”);
d) if ( 100>50 )
Q6: What is i-else statement? ( why if-else statement is
used)? printf(“ONE”);
else
Q7: Write the syntax of if-else statement.
printf(“TWO”);
Q8: convert the following in if else
LONG Question:
X< 0 ? y=10 : z=20;
Q9: Determine the output Q1: What is the control structure? Explain
Int x =10; its Types.
(x% 2 ? printf(“even”) :printf(“odd”)); Q2: Explain nested if statement with its
Q10: Write the expression for following in C-language. purpose, Syntax flow chart and suitable
a) Y is grater than x and less than 2. program
b) Marks are grater than 70 and less than 80. Q3: Define and explain If-else statement.
c) Temperature is between 25 and 35.
d) W is either equal to 6 or not greater than 6.
Q4: Write a program that inputs three
e) Age is greater than equal to 20. number and find the smallest number using
f) Speed is not greater than 65. nested if.
g) Temperature is less than 40.00 and greater than Q5: Write a program that accept three
25.00 number from user and display the largest
Q11: What is nested if statement? Write its syntax. number using nested if.
Q12: What is if-else if statement? Q6: Define if- else if statement. Explain its
Q13: What is meant by conditional operator? working with syntax, flow chart and give an
Q14: Write the syntax of switch statement. example.
Q15: Why brake statement is used in switch () structure? Q7: Write a program that display largest
Q16: What is the purpose of default statement in switch
number using if-else if.
structure?
Q17: trace the output of following codes. Q8: Write a program that input a weekday
a) Int k=8, m=7, z; number and print the name of the day.
Z=k ? k++ : m++; Q9: Write a program that input a character
printf(“%d”, z); and check whether it is a vowel or not using
b) Int p=3, q=5; switch statement.
If ( (p>q) ||(p!=4))
Q10: What is switch statement? Explain its
{ p=p+1;
working with flow chart syntax and an
q=q+1;
example.
printf(“%d, p-q); }
Q11: What is if statement? Explain in Details
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 12
Loop Construct
Short Question: Q2: Define while loop? Write its syntax and
Q1: What is meant by loop? flow chart. Also explain it working with the
Q2: Define infinite loop. help an example.
Q3: Define while loop.
Q4: Write down the use of loop. Q3: Write a program to print odd number 1
Q5: What is the syntax of While loop? to 10 using while loop.
Q6: Write a program to display first ten natural number by Q4: Write a program that prints the
using while loop. following series using loop:
Q7: What is do -while loop?
Q8: Differentiate between While and do-while loop. 19 16 13 10 7 4 1
Q9: Write the first ten odd number by using do-while loop. Q5: Write a program that get starting and
Q10: What is for loop? ending number then print counting in
Q11: What is syntax of for statement? between these numbers using while loop.
Q12: What is the role of test condition in for statement?
Q13: Write a program to print digit 1 to 10 using for loop. Q6: Write a program that input a number &
Q14: Write a note on counter control loop. print its table by using loop.
Q15: What is nest loop? Q7: Write a program that show the sum of
Q16: What is loop control variable? following using any loop
Q17: Why is sentinel value used in loop?
Q18: Define sentinel loop. 1+1/2+1/3+1/4+………..+1/100.
Q19: Define goto statement. Q8: What is do- while loop? Explain its
Q20: Convert the following for loop in while loop. working with example.
Int m;
Q9: Write the first ten odd number by using
for (m=10; m<5; m--)
printf (“%d\n”, m); do-while loop.
Q21: Convert in do while. Q10: Define for loop. Write its syntax and
a) Int a; flow chart. Explain its working with
for (a=1; a<=25; a++) example.
{ printf(“%d\n”,m); Q12: Write a program that display counting
a++; }
10 to 1 using for loop.
b) i=1;
While( i<=4) Q12: Write a program that input a number
{ from user and find its factorial.
printf(“world”); Q13: Write a program that print
i++; } 0 2 4 6 8 10 12 14 16
c) int I; Q14: write a program which print the sum
for ( I=3; I<=39; i+=6)
of following series
printf (“%d\n”, I);
d) int m=10; 1+4+9+16+25+……. +256.
for ( m=8; m>=1; m--) Q15: write a program in to print the given
printf(“%d”, m%2); series 0 3 6 9 12 15
Q16: Write a program to display the
Long Question: following series using loop. 1 4 9 16 25
Q17: What is nested loop? Write its syntax
Q 1 : Write a programm that displays first five odd
Numbers and their Average using loop
and explain its working, flowchart and
example.
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 13
Function in C
Short Question: Long Question:
Q1: Define Function. Q1: What is function? Write the types and
Q2: Write about unstructured programming languages. importance of function.
Q3: Describe Structure programming.
Q4: Write any two benefits of functions. Q2: Explain writing function in C languages.
Q5: Why function used in program? Q3 : how does a function return a value?
Q6: Give an example of user defined and built in function. How can this value can be Used?
Q7: List different type of function.
Q4: What are local variables, Explain
Q8: Define function declaration with its syntax.
Q9: How function is activated? lifetime and scope of local variable.
Q10: What is function call? OR How function is activated? Q5: What are global variables, Explain
Q11: What is function header? lifetime and scope of global variable.
Q12: What is function definition?
Q6: What is meant by function without
Q13: Write a note on function body.
Q14: What is return statement? argument? Write function return a value
Q15: What is function prototype? and accept argument.
Q16: Define scope of variable.
Q17: Write a difference between Global and Local variable.
Q18: Define automatic variable
Q19: Define global variable.
Q20: difference between actual & formal parameters.
Q21: What is meant by function without argument?
Q22: what is actual parameter?
Q23: what is formal/dummy parameter?
COMPUTER SCIENCE (2ND YEAR)
CHAPTER # 14
File Handling in C
Short Question: Long Question:
Q1: What is stream? Q1: What is array and string explain with
Q2: Write down the type of stream in file handling. examples.
Q3: What is text stream?
Q4: Define EOF marker. Q2: Why it is necessary to open a file? Write
Q5: Compare text and binary stream. different modes of opening a file.
Q4: Differentiate between newline and EOF. Q3: What is stream? Explain different types
Q5: Define file pointer? of streams.
Q6: Write the syntax of fopen () function.
Q7: Why it is necessary to open a file.
Q8: What is meant by closing a file.
Q9: How file is opened?
Q10: How file is closed?
Q11: What is string?
Q12: Define array in C language.
Q13: What is string assignment?
Q14: What is fgets() function?
Q15: What is fputs () function?
Q16: What are the names of function that are used for
formatted I/O in C Language.

You might also like