Tag Archives: #mastery01

#Mastery01 (probably 02)

Im leaving the link for a youtube video with me showing my .

 

https://www.youtube.com/watch?v=Rj0c8veDc10

 

cheers!

Mastery 01

Ability to Create a Python file and 

run from command line


Mastery 01

Ability to Create a Python file and 

run from command line


How to create a Python file and run it from the terminal #Mastery01

Here’s a quick tutorial video in spanish I made about how to create a Python file and run it rom a terminal:

https://www.youtube.com/watch?v=xr2Neu5csM4

 

Oscar Ricardo López López A01229116

Mastery 01 – Ability to create C++ file and run from command line

Ok, people. This is a video of how to create a C++ file and run it from terminal. 

Enjoy it.

https://www.dropbox.com/s/tisir8wk52wqzmx/Mastery%2001.mp4?dl=0

HELLO


HELLO

HELLO


DIEGO PLASCENCIA A01229988
I JUST DID A SIMPLE HELLO WORLD PROGRAM IN C++, IT JUST NEEDS COUT.

Create python file and run

i created my first “hello world” python file and ran it!

#mastery01- Ability to create a C++ file

 

Tener un programa: 

Primero se debe de tener un código (EL CÓDIGO SERÁ REGRESAR X + 1), para lo que se llama a la librería iostream, así como using namespace.

Después se define la main function, int main.

Una vez esto, se define el tipo de variable a utilizar y seguido de esto se escribe el nombre de la variable.

Se imprime el texto con un cout, y se pregunta por la variable.

Se guarda esa variable con cin.

Regresa la variable, y la suma de esa variable más uno. 

Guardar el programa en un lugar seguro, y guardarlo como un archivo cpp.

Por ejemplo, mastery01.cpp

 

Aquí está el código:

https://github.com/LuluisAngel/mastery-01-and-10/blob/master/README.md

 

Compilar y correr el programa con Cygdrive:

Primero se introduce cd /cygdrive/ 

Después de esto, se introduce (después de una diagonal /) la dirección en donde está el programa guardado, en mi caso /c/Programas. 

NOTA: Esto es donde tengo guardados mis programas, en el Disco Local, y en la carpeta llamada Programas.

Luego, se introduce ls, se mostrará un listado de los nombres de los programas que hayas realizado.

Después se introduce g++, y seguido de esto (en la misma línea), se escribe exactamente el nombre del programa que se desea abrir, incluyendo el .cpp

Una vez realizado esto, se escribe ./a.exe, lo que hará que corra el programa y, si hay algún error en él, abajo de esa línea te lo dirá.

Create python file and run!!

To complete this task we have to type our program on the editor (I would recommend Atom).

For this example we will just make a Hello World program by typing on the editor the next commands:

print (“Hello World”)

This will print the message in between the quotes directly on our screen.

Then we have to save it, for this example, we will save it as HelloWorld.py and put it on the desktop.

In order to run our program from a terminal, we have to open it and first of all,change the local directory. In case you are using windows you can do it by typing the following commands:

cd /cygdrive/c/users/manuel/desktop

In this case the selected user is manuel and the directory is the desktop, this will change depend on the case. Then, to run our Hello World Program we type on the terminal the following:

python Helloworld.py

This will run the program and it will show the message.

Create python file and run!!

#Mastery01 #TC1014

Create python file and run!!

#Mastery01 #TC1014 #LaNieveDeColimaExploto #PenguinLove

Para crear el Mastery01 solo imprimi una linea que dice Hello world y lo guade sin espacio y terminacion .py