Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PrajaktaSathe/Java
/ eat
Method
eat
Programs/Overriding.java:10–12 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
8
class
Boy extends Human{
9
//Overriding method
10
public
void
eat(){
11
System.out.println(
"Boy is eating"
);
12
}
13
public
static
void
main( String args[]) {
14
Boy obj =
new
Boy();
15
//This will call the child class version of eat()
Callers
1
main
Method · 0.95
Calls
no outgoing calls
Tested by
no test coverage detected