Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
this my code i try to complete it but I couldnt
I need to find the midean
import java.util.*;
import java.io.*;
class Task75{
public static void main(String[] args)throws Exception{
File myFile= new File("in.txt");
Scanner reader= new Scanner(myFile);
//PrintStream output=new PrintStream("output.txt");
ArrayList<String> store= new ArrayList<String>();
int i = 1;
while(reader.hasNext()){
String str = reader.nextLine();
System.out.println(str);
i++;
int j = i/2;
System.out.println(j);
}
}
}

doesn't look like a xp question. does look like a programming question. please try to post in the correct forums. Thanks

![]() |
![]() |
![]() |
| Login or Register to Reply | |
| Login | Register |
| Ads by Google |