21 lines
323 B
Java
21 lines
323 B
Java
public class Compteur {
|
|
|
|
private int compte;
|
|
|
|
public void plusUn()
|
|
{
|
|
this.compte++;
|
|
}
|
|
public String toString()
|
|
{
|
|
return Integer.toBinaryString(this.compte);
|
|
}
|
|
public Compteur()
|
|
{
|
|
this.compte = 5;
|
|
}
|
|
public static void main(String[] args)
|
|
{
|
|
System.out.println(toString());
|
|
}
|
|
} |