Calculator java applet program

Apr 14th, 2015
Studypool Tutor
Price: $5 USD

Tutor description

Calculator java applet program is a basic calculator that performs division,multiplication,addition and subtraction.

Word Count: 275
Showing Page: 1/3
PROGRAM DEVELOPMENT:import java.applet.*;import java.awt.*;import java.awt.event.*;/* */public class Calculator extends Applet implements ActionListener{ int i,n1=0,n2=0,c=0; String n=""; String r="",op=""; Button num[] = new Button[10]; Button add = new Button("+"); Button sub = new Button("-"); Button mul = new Button("*"); Button div = new Button("/"); Button mod = new Button("%"); Button eq = new Button("="); Button cl = new Button("C"); TextField nameField; public void init() { setLayout(new GridLayout(6,3)); for(i=0;i<10;i++) { num[i]=new Button(String.valueOf(i)); num[i].addActionListener(this); if(i!=0) add(num[i]); }; add(add); add(num[0]); add(sub); add(mul); add(div); add(mod); add(cl); add(eq); nameFi

Review from student

Studypool Student
" excellent work as always thanks for the help "
Ask your homework questions. Receive quality answers!

Type your question here (or upload an image)

1828 tutors are online

Brown University

1271 Tutors

California Institute of Technology

2131 Tutors

Carnegie Mellon University

982 Tutors

Columbia University

1256 Tutors

Dartmouth University

2113 Tutors

Emory University

2279 Tutors

Harvard University

599 Tutors

Massachusetts Institute of Technology

2319 Tutors

New York University

1645 Tutors

Notre Dam University

1911 Tutors

Oklahoma University

2122 Tutors

Pennsylvania State University

932 Tutors

Princeton University

1211 Tutors

Stanford University

983 Tutors

University of California

1282 Tutors

Oxford University

123 Tutors

Yale University

2325 Tutors