Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*in the name of Allah */
- # include <list>
- # include <deque>
- # include <bitset>
- # include <algorithm>
- # include <functional>
- # include <numeric>
- # include <utility>
- # include <sstream>
- # include <iostream>
- # include <iomanip>
- # include <cstdio>
- # include <cmath>
- # include <cstdlib>
- # include <ctime>
- # include <set>
- # include <map>
- # include <cmath>
- # include <queue>
- # include <limits>
- # include <stack>
- # include <vector>
- # include <cstring>
- # include <cstdio>
- using namespace std;
- # define MEM(array,w) memset(array,w,sizeof array)
- # define ULL unsigned long long
- # define eps 1e-9
- # define SS stringstream
- # define FOR(i, a, b) for (int i=a; i<b; i++)
- # define REP(i, a) FOR(i, 0, a)
- # define rive(s) reverse(s.begin(),s.end())
- # define PII pair<int , int>
- # define MPSS map<string, string>
- # define MPIS map<int, string>
- # define MPSI map<string, int>
- # define MPII map<int, int>
- # define MPIC map<int,char>
- # define MPCI map<char, int>
- # define all(c) (c).begin(), (c).end()
- # define VS vector<string>
- # define VI vector<int>
- # define VC vector<char>
- # define VB vector<bool>
- # define sz(x) x.size()
- # define pb push_back
- # define STI set<int>
- # define STC set<char>
- # define STS set<string>
- # define OK(R,C) if(i<0 && j<0 && j==C && i==R)
- template<class T> string toString(T n){ostringstream ost;ost<<n;ost.flush();return ost.str();}
- int toInt(string s){int r=0;istringstream sin(s);sin>>r;return r;}
- char one(int k)
- {
- cout<<endl;
- for(int i=0;i<k;i++)
- cout<<'|'<<endl;
- cout<<" "<<endl;
- for(int i=0;i<k;i++)
- cout<<'|'<<endl;
- }
- char two(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- }
- char three(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- }
- char four(int k)
- {cout<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';
- cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- }
- char five(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- }
- char six(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)cout<<'|'<<endl;
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- }
- char seven(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" "<<endl;
- }
- char eight(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';
- cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';
- cout<<" "<<endl;
- }
- char nine(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- for(int j=0;j<k+1;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- }
- char zero(int k)
- {
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<' ';
- cout<<" "<<endl;
- for(int i=0;i<k;i++)
- {
- cout<<'|';
- for(int j=0;j<k;j++)cout<<" ";
- cout<<'|'<<endl;
- }
- cout<<" ";
- for(int i=0;i<k;i++)cout<<'-';
- cout<<" "<<endl;
- }
- void delay(int n)
- {
- for(int i=0;i<60000;i++)for(int j=0;j<n;j++){}
- }
- int main()
- {
- int n;string s;
- rep:
- cout<<"Length; ";cin>>n;
- int time;
- cout<<"How long will continue: ";cin>>time;
- int i=0;
- system("cls");
- cout<<"Start?";
- getchar();getchar();
- start:
- cout<<zero(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<one(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<two(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<three(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<four(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<five(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<six(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<seven(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<eight(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- cout<<nine(n)<<endl<<" Your counting is now at "<<i<<endl;delay(6000);system("cls");
- i++;if(i==time){cout<<"FINISH. Continued until: "<<i<<endl;char r;
- q:
- cout<<"Want to count again? Press Y for YES, N for NO ";cin>>r;if(r=='Y')goto rep;
- else if(r=='N')return 0;else {cout<<"Wrong input. Press Y for YES, N for NO";goto q;}
- }
- goto start;
- cout<<"\n\n\n\n\n\n\nDesigned by Iftekhar ahmed eather,\nStudent of CSE (07 batch),\nBUBT, Mirpur";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement