Starting from:

$25

CTA200 -Assignment 1 Solved

The goal of this assignment is to practice using the command line and gitMake a Github account and create a new (public) empty repository called “CTA200” (or somethingof the sort).

1.      Create a local repository. Add the Github repository as the remote.

2.      Enter the folder for the local repository in your terminal. Using a text editor such as vi or gedit, createa simple ‘README.md’ file and a ‘LICENSE’ which contains the MIT license (find this online and copy/paste it).

3.      Commit your changes to the local repository.

4.      In your local repository, create a folder called ‘assignment 1’

5.      Copy the files ‘main.c’, ‘average.c’ and ‘average.h’ from the ‘assignment1 2020’ folder of the CTA200 course repository to your ‘assignment 1’ folder local repository.

6.      Using a text editor, create a ‘Makefile’ which builds and links the C program. Check that you can runthe program and it produces the right result (you should be able to identify what it does from the code without knowing any C).

7.      Commit the Makefile and the .c and .h files.

8.      Push the changes from your local repository to Github.

9.      (Bonus) Make a change to the C program and describe what you did in the comments (add at least 1 line somewhere). Commit the modified version with a useful commit message and push to your Github repository.

10.   Using the history command, save your command line history to a file called ‘history.txt’ to show howyou completed the tasks (hint: pipe the results of history to the tail command using the | operator to choose how many of the last n lines to show, you can redirect the output to a file using the operator). 12. Commit your history.txt file to the local repository and push the changes to Github.

More products