merry Christmas!

import java.io.*;

public class NickelDollar {
    public static void main(String[] args){
           
            BufferedReader BR = new BufferedReader(new InputStreamReader(System.in));
       
       
                    String num = "";
                System.out.println("How much Nickel do you have?" );
                System.out.println("How much Pennies do you have?" );    
       
        try
        {    
        num = BR.readLinne();
        int nickel = Interger.parseInt(num);
        num = BR.readLinne();
        int pennies = Interger.parseInt(num);
        int dollar = 0;
        int x = (nickel*5)+ pennies;
            dollar = x/100;
           
        System.out.println("You have" + x);
       
       
        }
        catch(IOException e) {
            Sytem.out.println("Error");
        }
           
        }
    }
}

I am new to programming, and I am making this ajava program.
The goal of the program is to convert the Inputed Nickel and pennies into dollar and cents.
And how could I make the output of dollar into something like this:
10 dollars and 4 cents.
Instead of just
10 dollars.

Any help will be appreciated, thanks

Check out the spelling. You've written: "Sytem", "Interger", "readLinne()".

Afther that, leave Buffers (reading data input from the user is not as simple as it's in C or C++) alone for a while, and try to grasp the Java Basics.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.