Skip to main content

Posts

10424 - Love Calculator UVA Solution

10424 - Love Calculator UVA Solution please do not copy it rather watch it for learning purpose :) Here is the code :-  #include <iostream> #include <bits/stdc++.h> #include <string> using namespace std; int getval(string nam); int reducingVal(int val);    int main(){        //MechaBoo     string name1,name2;     while(getline(cin,name1))     {         getline(cin,name2);         int par1= getval(name1);         int par2=getval(name2);         par1=reducingVal(par1);         par2=reducingVal(par2);               double x= par1*1.00;         double y=par2*1.00;           ...
Recent posts

11942 Lumberjack Sequencing - Solution

Solution of 11942  Lumberjack Sequencing- UVA please do not copy it rather watch it for learning purpose :) Here is the code :-  #include <iostream> #include <bits/stdc++.h> using namespace std; //MECHABOO  bool smallToBig(int arr[]);  bool bigToSmall(int arr[]);    int main(){     int test;     cin >> test;     for(int i=0;i<test;i++)     {         int arr[10];         bool nat;         for(int j=0;j<10;j++)         {             cin >> arr[j];         }         if(arr[0]>arr[1]||arr[1]>arr[2])         {           ...

UVA-11764 Solution

Solution of 11764 UVA number ! please do not copy it rather watch it for learning purpose :) Here is the code :- #include <iostream> #include <bits/stdc++.h> using namespace std;    int main(){        //mechaboo     int testCases;     cin >> testCases;     for (int i=0;i<testCases;i++)     {         int len,maxx=0,minn=0;         cin >> len;         int  arrJumps[len] ;         for(int j=0;j<len;j++)         {             cin >> arrJumps[j];             if(j!=0)             {       ...

URI ONLINE JUDGE -1044

Solution of 1044 number ! please do not copy it rather watch it for learning purpose :) #include <iostream> #include <bits/stdc++.h> using namespace std; int main () {     int a,b;     cin >> a >> b;     if(a<b)     {     if(b%a==0 ) cout << "Sao Multiplos" << endl;     else     cout << "Nao sao Multiplos" << endl;     }     else     {         if(a%b==0 ) cout << "Sao Multiplos" << endl;     else     cout << "Nao sao Multiplos" << endl;     }     return 0; } If you do not understand please leave a message here. or mail us mechaboo786@gmail.com or you can leave a message at fb . Link :- https://www.facebook.com/mechaboo/

URI ONLINE JUDGE -1043

Solution of 1043 number ! please do not copy it do it yourself use this as a guideline :) #include <iostream> #include <bits/stdc++.h> using namespace std; int main () {     double a,b,c;     cin >> a >> b >> c;     if(a<b+c&&b<a+c&&c<a+b)     {         cout << "Perimetro = "<<fixed << setprecision(1)<< a+b+c<<endl;     }     else cout << "Area = "<<fixed << setprecision(1)<< (((a+b)/2)*c)<<endl;     return 0; } If you do not understand please leave a message here. or mail us mechaboo786@gmail.com or you can leave a message at fb . Link :- https://www.facebook.com/mechaboo/

URI ONLINE JUDGE - 1042

Solution of 1041 number ! please do not copy it rather watch it for learning purpose :) #include <iostream> #include <bits/stdc++.h> using namespace std; int main () {     int a[3],b[3];     for(int i=0;i<3;i++)cin >> a[i];     for(int i=0;i<3;i++)b[i]=a[i];     sort (a,a+3);     for(int i=0;i<3;i++)cout << a[i] <<endl;     cout <<endl;     for(int i=0;i<3;i++)cout << b[i] <<endl;     return 0; } If you do not understand please leave a message here. or mail us mechaboo786@gmail.com or you can leave a message at fb . Link :- https://www.facebook.com/mechaboo/

URI ONLINE JUDGE - 1041

Solution of 1041 number ! please do not copy it rather watch it for learning purpose :) #include <iostream> #include <bits/stdc++.h> using namespace std; int main () {     double a,b;     cin >> a >> b;     if(a==0.0&&b==0.0)cout << "Origem" << endl;     if(a>0&&b>0) cout << "Q1" << endl;     if(a<0&&b>0) cout << "Q2" << endl;     if(a<0&&b<0) cout << "Q3" << endl;     if(a>0&&b<0) cout << "Q4" << endl;     if(a>0&&b==0)cout << ("Eixo X") << endl;     if(a<0&&b==0)cout << ("Eixo X") << endl;     if(b>0&&a==0)cout << ("Eixo Y") << endl;     if(b<0&&a==0)cout << ("Eixo Y") ...