Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
extends
//'main' method must be in a class 'Rextester'. //Compiler version 1.8.0_111 import java.util.*; import java.lang.*; class Rextester { public static void main(String args[]) { Student s = new Student(); s.setAge(18); s.setName("Tuan"); s.show(); } } class Person { int age; String name; void setAge( int age ) { this.age = age; } void setName(String name) { this.name = name; } void show() { System.out.println("Tuổi : "+age); System.out.println("Tên : "+name); } } class Student extends Person { }
run
|
edit
|
history
|
help
0
Please
log in
to post a comment.
Check Input
Integer to English Words
Java Q-2
Hello world
Dollar. java
Java Array List
Odd Occurence Problem Template
String Palindrome
ZonedDateTime testing
Jh
Please log in to post a comment.