		#include <iostream>
		using namespace std;
		  int main()
	    {
		    int  i, n, number;
		    int  sum, max1, max2;
		    cout<<" please enter n : ";
		    cin>>n;
		    sum = 0;
		    max1 = max2 = -1;
		    for (i=1 ; i<=n ; i++)
	      {
		       cout<<" enter number : ";
		       cin>>number;
		       if (number < 0)  {
		           i--;
                    continue;
		       }
		       sum += number;
		       if (number > max1)
	          {
		          max2 = max1;
		          max1 = number;
		         }
		      else if (number > max2)
		          max2 = number;
		      }
		   cout<<"  Sum = "<<sum<< ",  Maximum 1= "<<max1<< ",  Maximum 2= "<< max2;
		   return 0;
		  }
