CS-74: Introduction To Internet Programming-December,2007

  JHARKHAND BOARD You are here
BACHELOR IN COMPUTER APPLICATIONS

Term-End Examination

December, 2007

CS-74 : INTRODUCTION TO INTERNET PROGRAMMING

Time: 3 hours Maximum Marks : 75

Note:

(i) Question number 1 is compulsory.

(ii) Attempt any three questions from the rest.

1. (a) What is byte code in Java ? Explain.(4)

(b) What are the differences between abstract classes and interfaces in java ? Explain. (6)

(c) What are the native methods in java ? Explain.(4)

(d) How does repaint( ) method work for the applet ?(5)

(e) Find the error(s) if any. Also correct the error(s) and give the output. (4)

Class Scope ( int y = 10;

{intx =5;

system. out. pri ntln(" x=' +x) ;

system.out.println('' y= +y);

{ int x = 10;

system.out.println('' x= +x);

system.out. println("y="+y);

)

)

)

(f) What are the command line arguments in java ? Explain with example. (5)

(g) What is this pointer ? Explain.(2)

(a) Write a program to print all the contents of a. text file on screen. Name of the file is entered by the user. (7)

(b) What is the difference between run-time and compile-time polymorphism ? Explain with examples. (4+4)

3. (a). Write a Java program to display a button labelled "IGNOU". (6)

(b) What is exception handling in java? What is the advantage of finally block ? Explain.(7)

(c) package p1;

public class X {

int i = 10;

public int j = 5;

protected int k = 7;

private int w = 2;

)

If there is another package called p2, what are the variables of class X that can be accessed in a class in p2 ? (2)

4. (a) What are the thread priorities in java ? Explain with,the help of a suitable example. (7)

(b) What is NumberFormatException() in java ? When is it used ? Explain with example. (5)

(c) What are the following: (3)

(i) final class

(ii) final variable

(iii) final method

5. (a) How does one use multiple inheritance in java ? Explain. with example.(8)

(b) What is a toString() function in java ? Explain with example. (4)

(c) What is static data in a class ? Explain.(3)