Facebook
From Squa, 2 Years ago, written in C++.
This paste is a reply to Re: Iso from Squa - go back
Embed
Viewing differences between Re: Iso and Re: Re: Iso
#include 
using namespace std;
int main()
{
        int n;
        cin >> n;
        int i = 2;
        bool flag = false;
        while(i <= n && !flag)
        {
                if(n != 2)
                {
                        if( n % i == 0)
                        {
                                flag = true;
                                break;
                        }
                        else
                        {
                                i++;
                        }
                }
              else
        {
          flag = true;
        }
        }
        if(flag)
        {
                cout << "zlozona";
        }
        else
        {
                cout << "zlozona";
"pierwsza";
        }
        return 0;
}

Replies to Re: Re: Iso rss

Title Name Language When
Re: Re: Re: Iso Squa cpp 2 Years ago.