Need help,
code works fine but the final condition doesn't satisfy. is it a bug?
package com.codegym.task.task04.task0420;
/*
Sorting three numbers
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
//write your code here
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String s = br.readLine();
int a = Integer.valueOf(s);
String q = br.readLine();
int b = Integer.valueOf(q);
String t = br.readLine();
int c = Integer.valueOf(t);
int d = 0,e = 0,f = 0;
if(a<=b && b>=c)
{
d = b;
if(a>=c)
{
e = a;
f = b;
}
else{
e = b;
f = a;
}
}
else if(a>=b && a>=c)
{
d = a;
if(b>c)
{
e = b;
f = c;
}
else
{
e = c;
f = b;
}
}
else if(a<=c && b<=c)
{
d = c;
if(a>b)
{
e = a;
f = b;
}
else{
e = b;
f = a;
}
}
System.out.print( d + " " + e + " " + f);
}
}