title: How do i move a function around the screen using msvcrt and colorama?
body: <p>I'm new to programming and i need to print a triangle shape on specific coordinates and then use the arrow keys, getch and Cursor to move it around. I've already figured out how to print it in specific coordinates yet i cannot get getch to reprint the triangle on the coordinates around it.</p>
  <pre><code>def trian():
  from msvcrt import kbhit, getch, getche;
  from colorama import init,Back, Fore, Style,Cursor;
  import os;
  init();
  print(Back.BLACK + Fore.GREEN + &quot; &quot;);
  lineas=10;
  y=10;
  x=50;
  key = ord(getch());
  for numero_linea in range(lineas):
      espacios=lineas-numero_linea-1;
      asteriscos=1+numero_linea*2;
      print((Cursor.POS(x,y)),&quot; &quot;*espacios+&quot;*&quot;*asteriscos);
      y = y+1;
  if key == 224:
      key == ord(getch());
      if key == 37:
          x = x-1;
          print ((Cursor.POS(x,y)),&quot; &quot;*espacios+&quot;*&quot;*asteriscos);
  </code></pre>
  <p>As you might tell i have no idea how to use getch correctly, i just kinda glued things that i found on the internet, could anyone instruct me on this?</p>