Question: C++ The below code draws a shape using Ascii code write down a function to rotate the shape in any direction drawn bY THE BELOW
C++
The below code draws a shape using Ascii code write down a function to rotate the shape in any direction drawn bY THE BELOW CODE
MAKE A FUNCTION TO ROTATE THE SHAPE DRAWN BY THE FOLLOWING CODE IN ANY DIRECTION
ALSO MOVE THIS SHAPE ON CONSOLE WINDOW
#include using namespace std;
void drawshape() { for (int i = 0; i < 4; i++) { cout << " " << char(196) << endl; cout << char(179) << "I" << char(179) << endl; } cout << " " << char(196) << endl; }
int main() { drawshape(); }
NOTE:
ALSO DRAW A BOARD such that Board draws itself after every placement
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
