public void saveHighScore(int score, String name){
        try{
            f= new FileWriter("HighScore.txt");
        }catch(IOException e){
            System.out.println("fail");
        }
        sort();
        Integer lowest = 1000;
        Integer lowestKey = 0;
        for(int i = 0; i<5; i++){
            if(Integer.parseInt(topScores[i][1]) < lowest){
                lowest = Integer.parseInt(topScores[i][1]);
                lowestKey = i;
            }
        }
        String s = new String();
        s = String.valueOf(score);
        topScores[lowestKey][0] = name;
        topScores[lowestKey][1] = s;
        
        
        for(int i = 0; i<5; i++){
            String toWrite = (topScores[i][0] + ", " + topScores[i][1]);
            char[] write = toWrite.toCharArray();
            
            try{
            f.write(write);
            f.write('\r');
            f.write('\n');
            }catch(IOException e){
                System.out.println("Fail - "+e.getMessage()+"\n\n"); e.printStackTrace();
            }
        }
        
        try{
            f.close();
        }catch(IOException e){
            System.out.println("fail");
        }
    }