CS3 Pu2 UT2 Scheme
CS3 Pu2 UT2 Scheme
PART B
Answer any two questions. Each carries two marks. 2x2=4
11. Explain any two file opening modes in data file handling .
File mode parameter Meaning Stream type
ios::app Append to end of file ofstream
ios::in Open file for reading only ifstream
12. Difference between put() and get() functions.
Put()- the put() member function belongs to the class ofstream and writes a single character to the
associated stream
get()- the get() member function belongs to the class ifstream and reads a single character to the
associated stream.
13. Explain any two components of E-R diagram.
1. Entity- it is represented by rectangles. an entity is an object or concept about which you want
to store information.
PART C
Answer any two questions. Each carries three marks. 2x3=6
15. What is pointer? Give declaration and initialization of pointer.
Pointer- A pointer is a variable that holds a memory address usually the location of another variable
in memory.
Syntax
Data_type *variable_name;
Ex . int *x;
Here the presence of * indicates that it is a pointer variable.
Defining a pointer variable
int *iptr; (iptr-integer pointer)
float *fptr; (fptr-float pointer)
char *cptr ; (cptr-char pointer) Pointer variable assignmentWe can assign the address of a variable to
a pointer variable. Syntax Data_type *variable_name=value;
Ex. int *x=10;
<img>
c) To add background colour webpage.
<background > <bg color
>
PART D
Answer any three questions. Each carries five marks. 3x5=15
19. What is inheritance? Explain the types of inheritance.
20. Write the advantages of inheritance.
1. Reusing existing code
2. Faster development time
3. Easy to maintain
4. Easy to extend
5. Memory utilization
21. Give the difference between manual and electronic file system.
22. Explain DBMS architecture.
1. Internal level- this level is also known as physical level. This level describes how the data is actually
stored in the storage devices. This level is also responsible for allocating space to the data. This is the
lowest level of the architecture.
2. Conceptual level- it is also known as logical level. it describes how the database appears to the
users conceptually and relationships between various data tables. The conceptual level does not
care for how the data in the database is actually stored.
3. External level- it is also known as view level. It shows only the relevant database content to the
users in the form of views and hides the rest of the data. So different users can see the database as a
different view as per their individual requirement.
23. Explain data processing cycle.
Data processing cycle- the information processing cycle consist of five specific steps.
1. input- this is any kind of data – letters, numbers, symbols, shapes, images or whatever raw data
put in to the computer system requires processing. Input data is provided to computer using
keyboard, mouse, scanner, microphone and the digital camera.
2. Processing- the processing is a series of actions or operations from the input data to generate
outputs.
3. storage- data and information not currently being used must be stored for later use. There are
two types of storage- primary and secondary. Primary storage is the computer circuitry that
temporarily holds data waiting to be processed (RAM) and it is inside the computer. Secondary
storage is where data is held permanently. A floppy disk, hard disk, CD-ROM.
4. output- the result (information) obtained after processing the data. The result may be in form of
reports (hard copy/soft copy). Some of the output can be animated with sound and video/picture.
5. communication- computers have communication ability which is wired or wireless communication
connections, data may be input a far, processed in a remote area and stored in several different
places and then be transmitted by modem as an email or posted to the website where the online
services are provided.