a
package com.codegym.task.task05.task0532;
import java.io.*;
/*
Task about algorithms
*/
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
int maximum = 0;
while(true) {
int x = Integer.parseInt(reader.readLine());
if (x <= 0)
break;
maximum = maximum > x ? maximum : x;
}
System.out.println(maximum);
}
}