Sunteți pe pagina 1din 10

Maharashtra State Board of Technical Education Subject: JAVA PROGRAMMI G Subject !

ode: "##$ Mar%s: &' Ti(e: # )O*R Test+,a,er+# -#. Atte(,t an/ T0o of the follo0in1 2 3 & 4 5 Mar%s a) What do you mean by garbage collection in java. b) Explain the term Wrapper class. c) How multiple inheritance is achieved in java? -&. Atte(,t an/ Three of the follo0in1 2 3 $ 4 #& Mar%s a) Write a java program to define a class Rectangle. ssume suitable members and calculate area and perimeter of the rectangle. b) !escribe the uses of final and super with respect to inheritance. c) !escribe the following methods related to "tring i) replace#) ii) compare $o#) d) What is a pac%age? How to create it? Maharashtra State Board of Technical Education Subject: JAVA PROGRAMMI G Subject !ode: "##$ Mar%s: &' Ti(e: # )O*R Test+,a,er+& -#. Atte(,t an/ T0o of the follo0in1 2 3 & 4 5 Mar%s a) &ive the purpose of each arguments used in the method fillarc#) b) What is finally bloc%? When and how it is used. &ive a suitable example. c) Explain the functionality of a '()E class. -&. Atte(,t an/ Three of the follo0in1 2 3 $ 4 #& Mar%s a) Explain the following methods related to thread i) wait#) ii) sleep#) b) !istinguish between applet and frame. c) What is an Exception? How it is handled? &ive suitable example. d) Write a simple applet program to display * Hello World +.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G Sa(,le Pa,er +# Mar%s: 5' Ti(e: $ )O*RS -#. Atte(,t an/ 7our of the follo0in1 #8 Mar%s a) "tate any four features of java. b) !escribe arithmetic operators with examples. c) !escribe different java access specifiers. d) How to create a pac%age? Explain with examples. e) What is difference between vector and array? &ive suitable example. f) Explain file input class with suitable example. -&. Atte(,t an/ Three of the follo0in1 #& Mar%s a) !efine the following terms i) "tatic method ii) &arbage ,ollection b) &ive the wor%ing of nonymous classes in details. c) !escribe the various levels of access protection available for pac%ages. d) Write an applet application that display the string *,lic%+ every time the mouse button is clic%ed. -$. Atte(,t an/ Three of the follo0in1 #& Mar%s a) What is a thread? !escribe the complete life cycle of thread. b) Write an applet for each of following graphics methods. drawoval#) - drawrect#) - drawline#) - filloval#) c) Write a program to implement the fibonacci series using any control structure d) What are similarities between (nterfaces and ,lasses? -2. Atte(,t an/ T0o of the follo0in1 a) #8 Mar%s

Explain the following terms with respect to exception handling. #.)$ry #/) catch #0)throw #1)finally b) Explain dynamic methods dispatch with examples. c) Write a program to create two threads so one thread will print odd numbers where as second thread will print even numbers between . to /2 numbers. -9. Atte(,t an/ Three of the follo0in1 #& Mar%s a) !escribe left shift and right shift operators with examples. b) How do we add class or interface to a pac%age? c) !raw the life cycle of an applet and explain it. d) !istinguish between #() (nputstream and Reader classes #(()3utputstream and Writer classes -8. Atte(,t an/ Three of the follo0in1 #& Mar%s a) How do applets differ from application programs with examples? b) Write a program to demonstrate uses of implementing interfaces. c) Write an applet program that accepts two input string using 4param5 tag and concatenate the strings and display it in status window. d) !efine an exception called *6o7atchException+ that is thrown when a string is not e8ual to *(ndia+.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G :inter +&''5 Mar%s: 5' Ti(e: $ )O*RS #.Atte(,t an/ 7O*R of the follo0in1 : #8 #a) "tate any four features of 9ava. #b) !escribe arithmetic operators with examples. #c) !escribe general structure of class with example. #d) What is a major difference between an interface and a class? #e) !escribe different forms of inheritance with example. #f) What is stream ? Explain various types of stream. II. #a) #b) #c) #d) Atte(,t an/ T)REE of the follo0in1 : #& What is method overloading : &ive one example. What is vector? (;low is it differ from an array ? Explain. !efine pac%age. How to create pac%age? Write the applets to thaw s8uare inside a circle.

III. Atte(,t an/ T)REE of the follo0in1 : #& #a) !escribe the complete life cycle of threads. #b) Write the steps involved in developing and running a local applet. #c) Write the program to convert a decimal number to binary form and display the value. #d) What are the similarities between classes and interfaces? IV. Atte(,t an/ T:O of the follo0in1 : #8 #a) Explain following methods related to threads< #.) suspend#) #/) resume#) #0)yield#) #1) wait#) #b) Explain substring=- concat#)- replace# )- trim# ) method of class string. #c) Write the program to create two threads so one thread will print ascending number where as second thread will print descending number between se8uence (to .> numbers. V. Atte(,t an/ T0o of the follo0in1 : #& #a) !escribe various ?itwise operators with examples. #b) How do we add class or interface to a pac%age? #c) How parameter is passed to the applet : Explain with example. #d) !escribe the most commonly used classes for handling i@2 related exceptions. VI. Atte(,t an/ T)REE of the follo0in1 : #& #a) How applets differ from applications ? Explain with examples. #b) Write the 9ava program to calculate area of circle in which implementation of interface as class type. #c) Write an applet program to display *Aolygons+ #d) Explain exception handling in java.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G Su((er +&''" Mar%s: 5' Ti(e: $ )O*RS #. Atte(,t an/ four #8 a) Why 9ava is popular for internet ? Explain. b) What are the uses of super and this with respect to inheritance ? c) !ifferentiate between class and interface. d) "tate any four decision ma%ing statement along with their syntax. e) Explain life cycle of thread along with diagram. f) What is stream? Explain serialiBation. &. a) b) Atte(,t an/ three #& Why 9ava is called truely object oriented ? Explain. What will be output of following code class static member C static int m D 2E static int n D 2E public static void main #string args FG) C int mD .2E int x D /2E system.out.println #*m H n+ H i H n)E xDmHn E system.out.println#*In+H x)E J J c) "tate various levels of access protection available for pac%ages. d) What is an exception ? How it is handled ? Explain with suitable example. $. Atte(,t an/ three: #& a) Write a program to generate 'ibonacci series for any number using loop. b) What is difference between array and vector ? Explain element t#) and dd element#) method. c) What is pac%age ? How they are created / Explain with example. d)What is thread ? What is difference between multiprocessing and multithreading? 2. Atte(,t an/ t0o : #8 a) What is ?yte;,ode ? Explain any two tools available in 9!K. b) What are the applications of wrapper classes ? Explain integer wrapper class. c) Write a program to implement the following hierarchy

9. Atte(,t an/ three: #& a) !ifferentiate between brea% and continue statement. b) !escribe following string class method with example i)length #) ii) e8uals #) iii) char t #) iv) compare$o#). c) What is synchroniBation ? How do we achieve it? d) How do you put an applet into webpage ? Explain. 8. Atte(,t an/ three : #& a) What do you mean by multiple inheritance ? How this is achieved in 9ava? b) Explain following clause with respect to exception handling. i) try ii) catch iii) finally iv) throw c) !ifferentiate between applet and application. d) Write a simple applet to thaw rectangle which is filled with red color.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G Sa(,le Pa,er +& Mar%s: 5' Ti(e: $ )O*RS -#. Atte(,t an/ 7our of the follo0in1 #8 Mar%s a) "tate any four features of 33As. b) !escribe )ogical operators with examples. c) What are naming convention rules of variable in 9ava? d) What do you mean by type casting? Explain with suitable example. e) What is difference between "tring and "tring?uffer,lass? &ive suitable example. f) Explain file 3utput class with suitable example. -&. Atte(,t an/ Three of the follo0in1 #& Mar%s a. What is ?yte;,ode? Explain any two tools available in 9!K b. &ive the wor%ing of inner and outer classes in details. c. Explain 4 pplet5 tag in H$7) file and how to pass parameter to an pplet. Explain pplet by creating for addition of two numbers d. Explain the following clause w.r.t. exception handling. #i) try #ii) catch #iii) throw #iv)throws -$. Atte(,t an/ Three of the follo0in1 #& Mar%s a. What is a pplet? !escribe the complete life cycle of thread. b. Write an applet for each of following graphics methods. a. get'amily#) - get'ont6ame#) - get"tyle#) - is(talic#) c. Write a program to implement the prime number generation using any control structure d. What are similarities between bstract,lass and ,lasses? -2. Atte(,t an/ T0o of the follo0in1 #8 Mar%s a. Explain the following terms with respect to exception handling. #.)is live #/) notify #0)wait #1)finally b. Explain dynamic methods dispatch with examples. c. Write java program to demonstrate following exception and explain each of them rithmetic Exception rray(ndex3utof?ound 6umber'ormatException rray"toreException -9. Atte(,t an/ Three of the follo0in1 #& Mar%s a. !escribe labeled continue - brea% with examples. b. How do we add class or interface to a pac%age? c. "tate difference between pplet and pplication d. !istinguish between #() overloading and 3verriding #(()(nheritance and Aolymorphism -8. Atte(,t an/ Three of the follo0in1 #& Mar%s a. Write the java to demonstrate life cycle of java? b. Write a program to demonstrate pac%age and its use. c. Related to applet explain paint - repaint - update method of pplet and demonstrate using java code. d. Write java to demonstrate how user can create its own exception and use the same for solving programmer purpose.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G :inter&''" Mar%s: 5' Ti(e: $ )O*RS #. Atte(,t an/ four a) Write all primitive datatypes available in 9ava with their storage siBes in bytes. b) Explain- why 9ava is called as true object oriented language. c) What is constructor ? Explain constructor overloading with example. d) Explain how user defined pac%ages are created and accessed in java. e) Explain following methods of vector class i) element t #) ii) remove Element iii) insert Element t # ) iv) add Element f) What are stream classes ? )ist any two input stream classes from character stream. &.Atte(,t an/ three : a) !escribe uses of LfinalM with respect to inheritance. b) )ist the advantages of vectors over arrays. c) Explain with example how to achieve multiple inheritance with interface. d) Write an applet which shows two concentric circles filled with red and yellow color respectively< $. Atte(,t an/ three : a) What is $hread Ariority ? Write default priority values and methods to change them. b) Write procedure to accept parameters to an applet. c) Write a program to accept a number and print its factorial. d) What is an abstract class ? Explain its use. 2.Atte(,t an/ t0o: a) What is thread? Explain life cycle of a thread with a diagram< b) !efine a class *employee+ with data members as empid- name and salary. ccept data for > objects and print it. c) Write a program to create two threads- one to print numbers in original order and other in reverse order from . to >2. 9.Atte(,t an/ three: a) Explain concept of 9N7 with respect to portability feature of 9ava. b) Explain how an interface differs from a class. c) Write the difference between 9ava applet and 9ava application. d) Explain serialiBation in relation with stream classes. 8. Atte(,t an/ three: a) Explain steps to create and execute an applet with an example. b) Write a program to implement following inheritance c) Write methods to accept data and calculate average of both the mar%s and sports weigtage to it. d) Write an applet to accept a username in the form of parameter and print LHello 4cusername5M. e) Write a program to input name and age of a person and throw an user;defined exception- if the entered age is negative.

Maharashtra State Board of Technical Education6 Mu(bai Subject: JAVA PROGRAMMI G Su((er &'#' Mar%s: 5' Ti(e: $ )O*RS #.Atte(,t an/ 7O*R of the follo0in1 a) )ist different data types in 9ava. b) "tate different features of 9ava. $hose ma%e if different from L, languageM. c) Explain constructor with example. d) !escribe public and private access specifiers. e) Why do we create interface ? f) !escribe different stream classes. &.Atte(,t an/ T)REE of the follo0in1 a) Explain method overloading with suitable example. b) Write a program to calculate percentage of 1 subjects and print in suitable format. c) What is pac%age ? How to create it ? d) Explain applet life cycle with suitable diagram. $.Atte(,t an/ T)REE of the follo0in1 a) Explain thread priorities and method to get and set priority values. b) Write a program to create an applet for displaying different shapes. c) Write a program to chec% whether the entered number is prime or not. d) Write four major differences between an (nterface and a class. 2.Atte(,t an/ T:O of the follo0in1 a) Write a program to create two threads so one thread will print . to .2 number where as second thread will print .. to /2 numbers. b) Explain the following terms with respect to exception handling. i)try #ii) catch #iii) throw #iv) finally c)Write a program to implement vector class and Ls method for adding and removing elements. 9.Atte(,t an/ T)REE of the follo0in1 a) Explain relational and logical operators in 9ava b)Write a program to implement interface as c) !istinguish between 9ava applet and 9ava application. d) !istinguish between #i) (nput stream and Reader classes #ii) 3utput stream and Writer classes. &ive one point each. 8.Atte(,t an/ T)REE of the follo0in1 : a) Write a program to set bac%ground and foreground color using applet. b) Write program which throws an exception as *(nvalid ge+ if user enters negative value for variable age and empname of an employee. c) ,reate an applet which accepts user name as a parameter for html page and displays numbers of character from it

d) Write a program to generate 'ibonacci series. . ./0>O.0 for any number using loop.

S-ar putea să vă placă și