Solution to the problem number 149 of AceptaelReto - 149.

Any questions do not hesitate to contact.

#include <iostream>
using namespace std;
int main()
{
   long int vel=0,velocidad;
   long int casos;
   while(1)
   {
       if(scanf("%ld",&casos)!=EOF)
       {
   for(long int i=0;i<casos;i++)
   {
       cin>>velocidad;
               if(velocidad>vel)
                   vel=velocidad;
   }
   cout<<vel<<"\n";
   vel=0;
       }
       else
           break;
   }

  return 0;
}

Don't miss anything.

Keep in touch with Isaac Lozano Osorio!