#include <iostream>
#include  <cstdlib>
#include <ctime>

using namespace std;

int porownanie_liczb(int n,int o)
{
    if(n==o) cout<<"dobry jestes";
    else cout<<"o kurde";
    return 0;
}

int main()
{
    int k,l,m,wynik;
    srand(time(0));
    k=(rand()%10)+1;
    l=(rand()%10)+1;
    m=k*l;

    cout<<k<<" pomnozone przez "<<l<<" = "<<endl;
    cin>>wynik;
    porownanie_liczb(m,wynik);

    return 0;
}

@@@@@@@@@@@@@

#include <iostream>
#include <cstdlib>
#include <ctime>

using namespace std;

int losowanie_liczb()
{
    int k,l,m,wynik;
    srand(time(0));
    k=(rand()%10)+1;
    l=(rand()%10)+1;
    m=k*l;

    cout<<k<<" pomnozone przez "<<l<<" = "<<endl;
    return m;
}

int main()
{ int a,b;

    a=losowanie_liczb();
    cin>>b;
     if(a==b) cout<<"dobry jestes";
    else cout<<"o kurde";

    return 0;
}