Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.io.File;
- import java.io.FileNotFoundException;
- import java.util.Scanner;
- public class insertionSort {
- public static void main(String[] args) {
- File file = new File("test.txt");
- try {
- Scanner sc = new Scanner(file);
- while (sc.hasNextLine()) {
- String i = sc.nextLine();
- System.out.println(i);
- }
- sc.close();
- }
- catch (FileNotFoundException e) {
- e.printStackTrace();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement