arrays - java object oriented programming -


first off im new here. , dont know if peoples able me hope can me. thing have java exam object oriented programming , methods , classes , wasnt there when had , received image of exam , have = 0 knowledge java. can basic java code never looked new stuff. have on exam 2 tasks . post exam down below .

task 1. ------------------------------ class student  classvariable (private) lastname, firstname, gender, birthyear  of student  constructor  4 values added constructor.the values in  constructor assigned class variables.  method tostring() data students (the 4 class variables) connected string , stored in variable . form: lastname: muster firstname: max birthyear : 1997 gender: male variable returned mehod.  method outputstudentdata() string method tostring() print out.   task 2. ------------------------------- class schoolclass  classvariable suitable container store school class indefinite number of students (static, array, arraylist ...)  method outputclasslist() every student in classroom index number of container , 4 properties surname, first name, year , gender output (use method outputstudentdata() student class!)  method deletestudent() can enter index number of student you'd delete , student deleted container (see default output)  method classsize() classsize (amount of student in  class) output. (see default output)  method setstudent() can enter last name, first name, gender , birthyear of new student(see default output) new object of class student created. method returns object of class students back.  method main() following menu show up:  do? 0 > exit 1 > create new student , add schoolclass 2 > delete student schoolclass 3 > show classlist 4 > show classsize enter choice :    can enter choice. choice executed. if enter not valid number(not 0 - 4), errormsg appear. programm loop until numeric code 0 choosen. message appears adoption  executed, have chosen. enter not valid number (not 0-4), error message appears, program repeated until numeric code when choosing 0 message appears adoption. 

i hope can explain me how works in advance

and please dont think want spoonfeeded. im here learn how it. dont want fail on exam

reticulated spine , gamedroids correct in not question suitable stack overflow. simple google search turns many, many resources available use.

to started, this tutorial should getters, setters, , tostring, , should able use google figure out rest of assignment.


Comments

Popular posts from this blog

python - TypeError: start must be a integer -

c# - DevExpress RepositoryItemComboBox BackColor property ignored -

django - Creating multiple model instances in DRF3 -