Elite Coders Society
Hello Guest!
Join us here in this forum!
Please Log in or Register to access more feature in this site.
Start Learning!

† Copyright ©️ 2011 - EliteCoders.forums.ag †
Elite Coders Society
Hello Guest!
Join us here in this forum!
Please Log in or Register to access more feature in this site.
Start Learning!

† Copyright ©️ 2011 - EliteCoders.forums.ag †


Start sharing and learning new skills about programming and design by building connections with other professional and students.
 
HomeForumjava - Data Java. 2a512xyPortalLatest imagesGalleryjava - Data Java. Dw6hztSearchjava - Data Java. 2ns506pjava - Data Java. 2dt2b75RegisterLog in
Elite Coders Partner Links

EliteCoders™️ News!
Hello Guest!, Welcome in our forum. Be active!

Share | 
 

 Data Java.

View previous topic View next topic Go down 
AuthorMessage
Admin[dElmARk]
Admin[dElmARk]
Forum Owner
Forum Owner

Posts : 78
EC-Points : 6304
Thanked : 21
Join date : 15/10/2011
Age : 28
Location : Philippines

Hacker's Info
Hacking Exp:
java - Data Java. Left_bar_bleue0/0java - Data Java. Empty_bar_bleue  (0/0)
Hacker Type: White Hat
Hacking Title:

java - Data Java. Empty
PostSubject: Data Java.   java - Data Java. EmptyFri Nov 25, 2011 11:21 am

startData.java
Code:
import java.util.*;
public class startData{
    public static void main(String[]args){
    Scanner xx = new Scanner(System.in);
    Data lol = new Data();
    System.out.print("Input x");
    int x = xx.nextInt();
    System.out.print("Input y");
    int y = xx.nextInt();
    System.out.print("Input z");
    int z = xx.nextInt();

    System.out.println(lol.add(x));
    System.out.println(lol.add(x, y));
    System.out.println(lol.add(x, y, z));
    }
}
Data.java
Code:

class Data{
int x, y;
    public int add(int x){
          return x+5;}
    public int add(int x, int y){
          return x+y;}
    public int add(int x, int y, int z){
          return x+y+z;
    }
}
Back to top Go down
 

Data Java.

View previous topic View next topic Back to top 

 Similar topics

-
» Data Sorting: BubbleSort Java
» Data Sorting: InsertionSort Java
» Data Sorting: SelectionSort Java
» Cashier Java
»  Employee Java
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Elite Coders Society :: Software Development :: Java Programming :: Object-Oriented Programming (OOP) Java-

Protected by Copyscape Duplicate Content Finder
Powered By EliteCoders™

Elite Coders Partner Links
GreyPhantomYour Link HereYour Link HereYour Link Here
Yahoo!GoogleFacebookForumotion