Skip to content

Commit 94bdfad

Browse files
Chapter 8 Practice Set Solutions
1 parent d141dee commit 94bdfad

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

39.Chapter_8_Practice_Set/README.md

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Java Tutorial: Basic Questions on Object Oriented Programming
2+
3+
1. Create a class Employee with the following properties and methods:
4+
- Salary (property) (int)
5+
- getSalary (method returning int)
6+
- name (property) (String)
7+
- getName (method returning String)
8+
- setName (method changing name)
9+
10+
2. Create a class cellphone with methods to print “ringing…”, “vibrating…”, etc.
11+
3. Create a class Square with a method to initialize its side, calculating area, perimeter etc.
12+
4. Create a class Rectangle & problem 3.
13+
5. Create a class TommyVecetti for Rockstar Games capable of hitting (print hitting…), running, firing, etc.
14+
6. Repeat problem 4 for a circle.

0 commit comments

Comments
 (0)