import java.util.Arrays;
import java.util.Scanner;
public class l9 {
public static void main(String[] args){
class Arr{
int[] mass;
void sayLen(){
if (mass == null) {
System.out.println("0");
} else {
int len = this.mass.length;
System.out.println(len);
}
}
void addToMass(int e){
if (mass == null) {
this.mass[0] =e;
} else {
this.mass[mass.length+1] = e;
}
}
}
Arr arr = new Arr();
Scanner in = new Scanner(System.in);
while (true){
try {
int a = in.nextInt();
System.out.println(a);
arr.addToMass(a);
arr.sayLen();
}
catch (Throwable e){
System.out.println(e);
break;
}
}
}
}
List<Integer> mass;
void sayLen(){
if (mass == null) {
System.out.println("0");
} else {
int len = this.mass.size();
System.out.println(len);
}
}
void addToMass(int e){
if (mass == null) {
mass = new ArrayList<>();
this.mass.add(e);
} else {
this.mass.add(e);
}
}
}