0% found this document useful (0 votes)
47 views3 pages

Roll NO Subject Code No 065 Time Allowed: 3 Hours Maximum Marks: 14 Informatics Practices - Practical Session 2012-13

The document describes a GUI programming assignment involving credit card payment discounts. It includes: 1) Setting additional discount and net amount fields to 0 and uneditable initially. 2) Calculating discount based on bill amount and displaying in a field. 3) Calculating additional 5% discount if over $25,000 and displaying. 4) Enabling a button to calculate net amount by subtracting discounts from total. 5) Calculating and displaying net amount by subtracting discounts from total when the button is clicked. The document also includes 5 SQL questions about manipulating and querying data from an exam table.

Uploaded by

Ankur Papneja
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views3 pages

Roll NO Subject Code No 065 Time Allowed: 3 Hours Maximum Marks: 14 Informatics Practices - Practical Session 2012-13

The document describes a GUI programming assignment involving credit card payment discounts. It includes: 1) Setting additional discount and net amount fields to 0 and uneditable initially. 2) Calculating discount based on bill amount and displaying in a field. 3) Calculating additional 5% discount if over $25,000 and displaying. 4) Enabling a button to calculate net amount by subtracting discounts from total. 5) Calculating and displaying net amount by subtracting discounts from total when the button is clicked. The document also includes 5 SQL questions about manipulating and querying data from an exam table.

Uploaded by

Ankur Papneja
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Roll NO Subject Code No 065 Time Allowed : 3 hours Maximum Marks : 14

Informatics Practices Practical Session 2012-13 Q 1: Mr. Radhey Shyam Bansal the owner of the Kiddi Land Enterprises has asked his programmer Ekta to develop the following GUI in netbean

Mr. Bansal accepts payment through three types' of credit cards The discount is given according to the following scheme:

If the Bill amount is more than 25,000, then the customer gets an additional discount of 5% Write Java code for the following: i. To assign Additional Discount as 0 (jTextField4) and Net Amount as 0 (jTextField5). Also Set them as un-editable. [ When Calculate Discount (jbutton1) is clicked ]

ii.

To Calculate discount as per given criteria and display the same in jTextField3 To assign Additional Discount (jTextField4) as 5% of amout(jTextField2) as per the above condition To enable Calculate Net Amount (jButton2) button iii. * When Calculate Net Amount (jButton2) is clicked + To calculate Net Amount as [Total Cost (jTextField2) Discount(jTextField3) Additional Discount (jtextField4)] To Display the Net Amount in jTextField5.

2 2

Q 2: What will be displayed in JTextField1 after executing following code int m=16; m=m+1; if(m<15) jTextField1.setText(Integer.toString(m)); else jTextField1.setText(Integer.toString(m+15)); Q 3: What message will be displayed in Message Dialog after executing the following code int p,q=100; for(p=10;p<=12;p++) { Q+=p; } JOptionPane.showMessageDialog(null,P : +p+ Q :+q+); Q 4: What will be displayed in jTextArea1 after executing the following statement? jTextArea1.setText(cbse \n Practical Exam \t IP); Q 5: Consider the table exam given below. Write command in MySql for (i) to (v) and output for (vi) to (viii)

i. ii. iii. iv. v. vi. vii. viii.

To list the names of those students who have obtained first division in ascending order of name To display a report listing name, subject and annual stipend received assuming that the stipend column has monthly stipend To count the number of students who have either Accounts or Informatics as subject To insert a new row in the table exam: 6,Mohan,500,English,73,Second To display a list of students who have average in range 60-70 Select count (Distinct subject) from Exam; select avg(Stipend) from exam where division=Third; select min(average) from exam where subject=English;

1/2 1/2 1/2 1/2 1/2 1/2 1/2 1/2

You might also like