Question 1: [1X5=5]
- What is the difference between stack and queue?
- What is the use of try catch block?
- What is recursion technique?
- Multiply 111001 by 110
- Verify if (A+B)’=A’+B’ with the help of truth table.
Question 2: [2X5=10]
- Draw a logic circuit for the following booleanexpression A’+(B.C’+A’C)
2. In an array of real numbers A, ARRis stored in location 450. Find the address of A when the array is stores in column major wise & size of each word is 4 bytes.
3. Convert the following into postfix and prefix notation
A*[(B-C)/(D-E)]Differentiate half adder and full adder.
4. Explain Tautology and contradiction with example.
Question 3: 
the final value of q at the end of the following program segment:
Answer six questions in this part, choosing two questions from Section A, two from Section B and two from Section C.
Answer any two questions
Question 4: 
- Explain in detail the motto of FSF Free Software Foundation 
- Explain software copy rights? 
- Explain the following
- Privacy 
- Spam 
- What is Intellectual property? 
Question 5: 
- Differentiate half adder and full adder 
- Explain why NAND and NOR are called universal gate, also draw realizations of AND,OR using NAND & NOR 
- What is open soure software? 
Question 6: Convert the following. 
- (784)10=( )2
- (322.2)10=( )2
- (430.26)10=( )8
- (DE)16=( )2
- (1101110111)2=( )16
Answer any two questions
Each program should be written in such a way that it clearly depicts the logic of the problem. This can be achieved by using mnemonic names and comments in the program. The programs must be written in Java.
Question 7: 
Write a program according to the class specifications bellow
|Number(int n)||Constructor to assign class members|
|Int fact(int x)||To find factorial of any given number using recursion technique|
|Boolean isSpecial()||To check if the number is special or not|
145 is a special number because sum of factorial of each digit of the number is the same number again1!+4!+5!= 1+24+120=145,Also create a main class to call the functions down
Question 8: 
indexedarray contains the employee code of 100 employees. Some of the members
Class name :indexedarray
arr : int array
indexedarray() : to assign the code to 0.
voidfillarray() : to input the code in the arr.
voidsortarr() : to sort the array variable using selection sorttechnique.
intbinarysearch(int,int) : to search and return 1 if an employee code is foundin the array object dddddddddddddddddddddotherwise returns 0.
Specify the class indexedarray giving details of the constructor, void sortarr(), intbinarysearch(). Youmay assume that other member functions are written for you. You do not need to write the mainfunction.
Question 9: 
Stack is a kind of data structure which can store elements with the restriction that an element can be added or removed from the top only. The details of class Stack are given below:
Class name : Stack
st : the array to hold names.
size : the maximum capacity of the string array
top : the index of the topmost element of the stack
ctr : to count the number of elements of the stack
Stack() : default constructor
Stack(int cap) : constructor to initialize size=cap and top=-1
void pushname(String n) : to push a name into the stack. If the stack is full, displaythe message “overflow”.
String popname() : removes a name from the top of the stack and returnsit. If the stack is empty, display the message“underflow”.
void display() : Display the elements of the stack.
Stack giving details of the constructors(), void pushname(String n), String
popname() and void display(). The main function and algorithm need not be written.
Answer any two questions
Question 10: 
class stringop is designed to handle string related operations. Some members of
the class are givenbelow:
txt : to store the given string of maximum length 100.
stringop() : constructor
void readstring() : to accept the string
char caseconvert(int, int): to convert the letter to other case
void circulardecode() : to decode the string by replacing each letter by converting it
vvvvvvvvvvvvvvvvvvvvvvvvvvvvto opposite case and then by the next character in a circularway. vvvvvvvvvvvvvvvvvvvvvvvvvvvvHence “AbZ” will decode “bCa”.
Specify the class giving details of all member functions. You do not need to write function main().
Question 11: 
A class Merger concatenates two positive integers that are greater
than 0 and produces a newmerged integer. Example :- If the first number is 23
and the second is 764, then the concatenatednumber will be 23764. Some of the
members of the class are given below:
Class name : Merger
n1 : long integer to store first number.
n2 : long integer to store second number.
mergNum : long integer to store the merged number.
Merger( ) : constructor to initialize data members.
voidreadNum( ) : to accept the values of the data membersn1 and n2.
Void JoinNum( ) : to concatenate the numbers n1 and n2 andstore it in mergNum.
void show( ) : to display the original numbers and the
sssssssssssssssssssssssmerged numbers with appropriatemessages.
Specify the class Merger, giving details of the constructor, void readNum( ), void JoinNum() and voidshow( ). Define the main function to create an object and call the functions accordingly to enable thetask.
Question 12: 
- What is the difference between compareTo() and equals() String functions 
- Draw truth table for the following Expression.