aimon1337

Untitled

Apr 15th, 2021
400
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <iostream>
  2. #include <fstream>
  3. using namespace std;
  4. ofstream fout("iesire.txt");
  5. int main(){
  6.     int i,j,k;
  7.     int s1, s2;
  8.     cin>>s1>>s2;
  9.     for(i=1;i<=9 && i<=s1; ++i){
  10.         for(j=0;j<=9;++j){
  11.             for(k=0;k<=9 && k<=s2; ++k){
  12.                 if((s1-i>=0) && (s1-i<=9)){
  13.                     if((s2-k>=0) && (s2-k<=9)){
  14.                         fout<<i<<(s1-i)<<j<<k<<(s2-k);
  15.                         fout<<endl;
  16.                     }
  17.                 }
  18.             }
  19.         }
  20.     }
  21.     fout.close();
  22.     return 0;
  23. }
  24. //1661
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×