Ans 1. (a) Java Bite Code / Object Program - -
correct answer 1 Mark
Source Code -> Compiler-> Object Program -> Linker -> Java Byte Code
Ans 1.(b)PARAM and PACE and Anurag ½ mark
for any two correct names.
1. Very Fast in Computing
2. Very Big Memory Size.
Ans 1(c) Firewall is a system (Hardware & Software) to safeguard or protect the system from unauthorized access (Hacking / Phishing)
2 marks
for definition.
Ans1.(e)
Types of Errors
Compile Time Error- Occurs during compile time. When a program compiles it sources code is checked for
rules of programming language.
Its types are:-
1. Syntax error : it occurs when a grammatical rule of Java is violated
2. Semantic error: it occurs when statement are not meaningful.
Run Time Error: Occurs during the execution of the program.
Logical Error: Occurs due to wrong logic of a program.
Logical Error: Occurs due to wrong logic of a program.
2 marks for explaining all
errors.
Ans 1. (f)
|
Bar Code Reader
|
Smart Card Reader
|
|
1. This device is used to read
barcode strip printed in any product/item.
|
1. This device is used to
access/read electronic chip
on the smart card.
|
|
2. It translates optical impulses
into electrical signals.
|
2. It consists microprocessor and none-volatile memory to store and process the digital data.
|
There may be any two points difference.
Each point 1 x 2 =2 Mark
Ans 2 (a) ComboBox - 01 Mark
Because it is more suitable for it.
It can hold all the values within confined space.
Ans 2. (b) jCheckbox. / JList 1 mark for correct answer.
Ans 2. (c) The Java programs need to be
written just once, which can be run on different platforms without making
changes in theJava program. Only the Java interpreter is changed depending upon
the platform.This characteristic is known as Write Once Run Anywhere.
(2 marks for complete answer)
)Ans2.(d)Spyware is a type of malware (malicious software) installed on computers that collects information about users without their knowledge. The presence of spyware is typically hidden from the user and can be difficult to detect. Some spyware, such as keyloggers, may be installed by the owner of a shared,corporate, or public computer intentionally in order to monitor users.
Malware:
Short for "malicious software," Malware refers to software programs designed to damage or do other unwanted actions on a computer system.
1 mark for each threat
details.
Ans 2. (e)StringAns=( (x%2==0) ? ”even”: “odd”)
2 mark for correct
answer
Ans
2(f) 1
mark for def and 2 for recycle and recovery process.
Ans3.(i) Primary Key : It is the column or set of columns which can uniquely
identify each tuples(rows) of the
relation(table).
Alternate Key : It is column or set of columns which is not used for
uniqueness of the tuples. It is the candiadate key which has selected as
primary key purpose.
Table ADMISSION ( ADMNO,ROLLNO,STNAME,CLASS,SECTION,DOADM,ADRR,DOB)
ADMNO – is the primary key
ROLLNO – is the alternate key(it may have duplicate class values )
Each correct definition ½x
2 = 1 Mark and Examples ½ x 2 = 1 Mark
Ans.3(ii)Phishing : Phishing is attempting to acquire information (and sometimes, indirectly, money) such as usernames, passwords, and credit card details by masquerading as a trustworthy entity in an electronic Communication.
2
mark for correct definition
Ans3.
(iii) 2 marks for correct answer.
Ans3.(iv)
Degree of a relation is the total number of columns in the table and
cardinality is the total number of rows in the table.
1
mark for each correct answer
Ans3.(v)
2 marks
for correct answer
Ans 4. (a) jTextField1
- 25 marks for correct answer
Ans
4(b)corrected code
int Total=0 ,Jump=5;
int I;
for( I=0;I<=5;i++)
{
Jump +=5;
Total = Jump;
}
jTextArea.setText( “”+Total);Each correct errors ½ Mark
x 4 = 2 Marks
Ans 4. (c) X = 50 Y = 48 correct answer- 2 Marks
, Partial Answer- 1 Mark
Ans 4. (d)intItemCode;
String Product;
if ( ItemCode == 1001 )
Product=”Vegetables& Fruits”;
else if( ItemCode==2002 )
Product=” Bakery Items”;
else if( ItemCode==3003)
Product=” Cereals”;
else if( ItemCode==4004)
Product=”Juice & Soft Drinks”;
else if( ItemCode==5005)
Product=”Cosmetics”;
else
JOption.showMessageDialog(null,”Select an appropriate
ItemCode”);
Correct Answer 2 Mark , Partial answer – 1 Mark
Ans 5 i is 11 and n is 0.
½ mark for each.
Ans6Float costp =
Float.parseFloat( jTextField1.getText() ) ;
½ Mark for each statement
Integer Nop=
Integer.parseInteger(jTextield2.getText() );
Float STax =
TotAmt * (20 /100) or 0.2; 1 Mark for each statement
jTextField4.setText(“” +
STax); ½ Mark for each statement
Ans7
(1)BillnoTF.setText(“”);
NameTF.setText(“”);
PriceTF.setText(“”);
DiscTF.setText(“”);
FinalTF.setText(“”)
MensRB.setSelected(TRUE);
Each
correct statement ½ Mark
Ans 7 (2) Code for Exit button ½ Mark
System.exit(0);
To Make
the TextFieldsDiscTF and FinalTFuneditable
DiscTF.setEditable(FALSE);
FinalTF.setEditable(FALSE); for two statements ½ Mark
Ans 7 (3) For calculation of the Discount and Final price , consider only price value
to be entered.
Float Price= Float.parseFloat(PriceTF.getText() );
Float
DiscAmt,FinalAmt
if ( MensRB.isSelected( ) )
{ if ( Price <1000)
{ DiscAmt = Price * 0.3; or
Price * (30/100) ; }
else
{ DiscAmt = Price * 0.5; or
Price * (50/100) ; }
}
if(WomensRB.isSelected() )
{ if ( Price <1500)
{ DiscAmt = Price * 0.4; or
Price * (40/100) ; }
else
{ DiscAmt = Price * 0.5; or
Price * (50/100) ; }
}
if(KidsRB.isSelected() )
{ if ( Price <500)
{ DiscAmt = Price * 0.2; or
Price * (20/100) ; }
else
{ DiscAmt = Price * 0.3; or
Price * (30/100) ; }
}
if(MemberCB.isSelected( ) )
{
DiscAmt =
DiscAmt + (0.05 * Price );
}
FinalAmt = Price – DiscAmt ;
DiscTF.setText(“”
+ DiscAmt);
FinaTF.setText(“”+ FinalAmt);
1 – Mark
for correct use of if statement for selecting category
1 – Mark for correct use of if statement checking percent and
discount amount
½ Mark calculate Final amount .½
Mark to display these two values in TextFields.
Ans 8(a) KVS RAIPUR
REGION 2017
1 mark for TAB and 1 for NEWLINE.
Ans 8(b) import javax.swing.JOptionPane;
Joptionpane.showMessageDialog(null,”DIGITAL
INDIA”);
1 mark for each line
Ans
8 (c)int age;
String txt = agetf.gettext();
age = integer.parseint (txt);
if (age <18)
msglbl.setText(“you are
not eligible to vote”);
else
msglbl.setText(“you are
eligible to vote”);
1
mark for correct logic, 1 for var declaration and parse, 1 forcorrect if else
structure.
Ans
8 (d)int a;
for ( a= 1; a<=20; a++)
{ if(a%2==0)
System.out.println(a);
}
1/2
mark for each statement.
Ans
8 (e) for (i=1; i<=10; i++)
System.out.println( i);
1 mark for for structure and 1 mark for
println statement
Ans 9(a) comments provide
explanatory notes to the readers of the program.
indentation makes the program
more readable and presentable.
1
mark for each explanation.
Ans 9(b) 2 marks for correct
difference .
Ans9(c)the steps are:-
1. understand
the problem well.
2. analyse
the problem.
3. design
the program by deciding step by step solution in simple steps.
4. code
the program.
5. tset
and debug the program.
6. complete
the documentation.
7. maintain
your program.
2 marks for correct answer.
Ans 9. (d) 1 Text Box
2 Option Button
3 Combo Box
4 Command Button
½ mark each for each
correct control name.