Questions on C
- · Difference between array and pointer. Among them which one is dynamic?
- · Difference between array and structure
- · Difference between structure and union.
- · Name the data types in C
- · Syntax of Switch
- · What is a datatype?
- · Write any C program.
- · What is the range of short int?
- · Difference between C and Java?
- · Difference between C and C++?
- · What is a pointer?
- · What is an array?
- · What is structure?
- · What is union?
- · Write the palindrome program in C
- · Program on concatenation of strings without using strcat().
- · Program on reversing a given string without using strrev().
- · Program on comparing two strings without using strcmp().
- · Program on bubble sort.
- · Program to find the factorial of a number.
- · Program to reverse a number.
- · To print average of 5 numbers using an array.
- · What r storage classes in C? Why r they required?
- · How many sorting techniques r there in C? What r they?
- · Why so many sorting techniques r required?
- · Using functions write a C program to find the addition of two numbers.
- · Write a program for reversing a string using pointers
- · Write any one sorting algorithm?
- · Using functions write a C program to find the product of two numbers
- · What is Stack? What order does it follow?
- · What is Queue? What order does it follow?
- Difference between function and procedure
- · What is binary tree? Does it have any condition?
- · Syntax of while, do while, for, if and small programs using them
- · What is the difference between while and do while loops?
- · A program, which is written in C, is given and was asked to find out the error.
- · Limitations of queue?
- · Tell what u know about data structures.
- · What is the difference between structure and data structure?\
- · Call by value and Call by reference? Write a program on them.
- i= -127.4327
printf(“%d”,i); ans)-127
printf(“%f”,i); ans)-127.4327
printf(“%u”,i); ans)127
printf(“%c”,i); ans)ascii character (once check this program)
- .Command used in C for reading an element
- · Command used in C for printing an element
- · What is your favorite subject and why????????
- · Name the subjects which u studied in last semester or the subject’s u r studying presently
- · Rate yourself in C.
- What is quick sort order and merge sort order? Which is used mostly?What is the most efficient sorting tech?
- Ans:In the worst case scenario:
merge sort runs in O(n.log(n)) time
In average case scenario:
quick sort runs in O(n.log(n)) time
merge sort runs in O(n.log(n)) time
(In the above, n refers to the number of elements being sorted)
Mostly quick sort is used because it is faster than merge sort in the average scenario. Also, unlike merge sort, quick sort does not need extra memory.
- What is AVL tree?
- What is 2-3 tree? Balanced tree?
To guarantee this property, insertion and deletion functions for the tree not only insert or delete an element; they also adjust the tree height after insertion or deletion.
In AVL trees, the height difference between left and right sub trees can be at most 1.
2-3 trees are also balanced trees, but they are not binary trees. Instead, each node can have at most 3 children in a 2-3 tree. For example:
- Difference b/w structure and data structure?
struct my_struct
{
int i1, i2;
char c;
};
A Data Structure is a language independent term. It is used for anything that holds data when a program is running. For instance, if you write a phone book program that lists your friends names and their phone numbers, you can use a LIST data structure to store this data. Or you can use a HASH data structure to store this data.
LIST or HASH or STACK or QUEUE data structures can be implemented in any language. If they are implemented using C language, then the implementer might use one or more C structures to implement LIST or HASH, etc.
For example, to implement a LIST data structure in C language, we commonly use the following kind of C structure:
struct Node
{
int data;
struct Node * next;
};
- Does every language need a compiler?????? Give an eg.. for both cases
- .Ans: No, not every language needs a compiler. For instance, there is a class of languages called interpreted languages that do not need a compiler.
E.g.: BASIC, Perl, Python. Perl and Python are also called scripting languages.
- · Different topologies (mesh, star, ring, bus, tree). Advantages and disadvantages of each topology.
- · Which topology is used in your college?
- · Difference between LAN, MAN, WAN.(different types of networks) Explain about them.
- · Name the OSI layers. What is the function of each layer?
- · What is a protocol?
- · What is an interface?
- · What is a layer?
- · HDLC, PPP, SDLC protocols.
- · What is a gateway?
- · What is a router?
- · What is a bridge?
- · Ethernet 10 base 2,10 base T
Questions on Database Management Systems
· Name some databases
· Keys in DBMS
· Difference between UNIQUE key and PRIMARY key.
· What r dml and ddl in dbms? What r their commands?
- Ans) DML (Data Manipulation Language) statements are used for managing data within schema objects. Some examples: Ans) DDL (Data Definition Language) statements are used to define the database structure or schema. Some examples:
- · CREATE - to create objects in the database
- · ALTER - alters the structure of the database
- · DROP - delete objects from the database
- · TRUNCATE - remove all records from a table, including all spaces allocated for the records are removed
- · COMMENT - add comments to the data dictionary
- · RENAME - rename an object
- DML (Data Manipulation Language) statements are used for managing data within schema objects. Some examples:
- · SELECT - retrieve data from the a database
- · INSERT - insert data into a table
- · UPDATE - updates existing data within a table
- · DELETE - deletes all records from a table, the space for the records remain
- · MERGE - UPSERT operation (insert or update)
- · CALL - call a PL/SQL or Java subprogram
- · EXPLAIN PLAN - explain access path to data
- · LOCK TABLE - control concurrency
- Normalization forms? Explain them.
- · All the commands in dbms like create, insert, count, drop, select……….
- · Command to count the number of records. Ans) count
- · Command to sort the records Ans) order by
- · Leaky bucket algorithm.
- · Is there any compiler in oracle
- · Diff between DBMS & RDBMS?? What r Codd rules???
- · How many types of relationship??? Eg. Of many-to-many relationship???
- · What is join??
- Does oracle need a compiler?
No comments:
Post a Comment