C++ alqoritm
Salam kod budur
[code]
#include <iostream>
#include <conio.h>
#include <string.h>
using namespace std;
int main(){
system("color 5a");
string ilan,left,right,up;
ilan="0000000000";
left=" ";
right=" ";
up="\n\n\n\n\n\n\n\n\n\n";
int a=0;
cout<<up<<left<<ilan<<right;
start:
switch(getch()){
case 'd':{
if(a==35){
goto start;
}
left=left+ " ";
a++;
system("CLS");
cout<<up<<left<<ilan<<right;
goto start;
break;
}
case 'a':{
goto start;
break;
}
default:{
goto start;
}
}
getch();
}
[/code]
Indi bu ilanın sola hərəkətin necə düzəldək?