Advertisement
Anik_Akash

Output 10

Oct 5th, 2020
229
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 3.07 KB | None | 0 0
  1. //thanks God For Every Thing!
  2. //contest link:
  3. /*
  4.  
  5.  
  6.                                  //  \\                            ।। \\                            ।।  ।।    ।।             //
  7.                               //        \\                         ।।   \\                          ।।  ।।    ।।          //
  8.                             //            \\                       ।।     \\                        ।।  ।।    ।।        //
  9.                           //                \\                     ।।       \\                      ।।  ।।    ।।      //
  10.                        //                     \\                   ।।          \\                   ।।  ।।    ।।   //
  11.                      //                         \\                 ।।             \\                ।।  ।।    ।।//
  12.                   //  _________________ \\                ।।               \\              ।।  ।।    ।।\\
  13.                 //  _________________      \\             ।।                  \\           ।।  ।।    ।।   \\
  14.               //                                       \\          ।।                     \\        ।।  ।।    ।।     \\
  15.            //                                            \\        ।।                        \\     ।।  ।।    ।।        \\
  16.          //                                                 \\     ।।                          \\   ।।  ।।    ।।           \\
  17.        //                                                     \\   ।।                             \\।।  ।।    ।।              \\
  18.  
  19.  
  20.  
  21.  
  22. */
  23.  
  24.  
  25.  
  26.  
  27. //#include<bits/stdc++.h>
  28. #include<iostream>
  29. #include<string>
  30. #include<algorithm>
  31. #include<cstdio>
  32. #define pi           acose(-1)
  33. #define flush        cin.ignore(numeric_limits<streamsize>::max(),'\n');
  34. #define wow          ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
  35. #define NL           "\n"
  36.  
  37. using namespace std;
  38.  
  39. typedef long long int           ll;
  40. typedef double                  dl;
  41.  
  42. // ---------------------- slove---------------------------//
  43.  
  44.  
  45.  
  46. int main()
  47. {
  48.  
  49.     for(int i=1; i<=5; i++)
  50.     {
  51.         for(int j=i; j<=7; j++)
  52.         {
  53.             printf(" ");
  54.         }
  55.  
  56.         for(int x=1; x<=(2*i)-1; x++)
  57.         {
  58.             if(x==1 || x==(2*i)-1)
  59.             {
  60.                 printf("%c", 64+i);
  61.             }
  62.             else
  63.             {
  64.                 printf(" ");
  65.             }
  66.         }
  67.         printf("\n");
  68.     }
  69.     for(int i=4; i>=0; i--)
  70.     {
  71.         for(int j=i; j<=7; j++)
  72.         {
  73.             printf(" ");
  74.         }
  75.  
  76.         for(int x=1; x<=(2*i)-1; x++)
  77.         {
  78.             if(x==1 || x==(2*i)-1)
  79.             {
  80.                 printf("%c", 64+i);
  81.             }
  82.             else
  83.             {
  84.                 printf(" ");
  85.             }
  86.         }
  87.         printf("\n");
  88.     }
  89.  
  90.     return 0;
  91. }
  92. /*
  93.        A
  94.       B B
  95.      C   C
  96.     D     D
  97.    E       E
  98.     D     D
  99.      C   C
  100.       B B
  101.        A
  102. */
  103.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement