Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package basicOOP;
- public class DoThings {
- public int doIt(int x, int y){
- return x*y;
- }
- public String thatThing(String x,int y){
- return x+y;
- }
- public void product(int max){
- int product=1;
- for(int i=1; i<max; i++){
- product*=i;
- }
- System.out.println(product);
- }
- public double calcs(double d1, int i1){
- return 0.0;
- }
- public String hello(String s){
- }
- public static void main(String[] args) {
- DoThings doIt=new DoThings();
- int var1=doIt.doIt(4,6);
- String s=doIt.thatThing("Hello", 15);
- doIt.product(5);
- double calcs=doIt.calcs(3.4,7);
- String s1=doIt.hello("World");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement