Link to home
Start Free TrialLog in
Avatar of keepworking
keepworking

asked on

2/4 ??

int i =2;
int j =4;

I want to print the result of (2/4%) as 50% in java, how to do it?

what I did:

int n=i/j ; I got n is 0;
ASKER CERTIFIED SOLUTION
Avatar of Mick Barry
Mick Barry
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial