Skip to content

Exercises

Aleksandar Karastoyanov edited this page Apr 5, 2023 · 19 revisions

The following exercises will help you in the process of getting familiar with the Bash console and working with Git.

Execute the assignments bellow, preferably on Linux Debian VM. If you don't have Linux virtual machine setup, you can download an exported .ova file for Oracle VM VirtualBox from the LINK. If you don't have yet a Git setup on your Linux VM follow the steps from this guide to generate SSH key and upload it to your GutHub profile


Task 1
  • 1️⃣ Write application which prints the Multiplication Table up to 10 and merge your file with the karastoyanov / linux-hobby-club / development

    • 1️⃣.1️⃣ Fork the original repository to your personal account

    • 1️⃣.2️⃣ Clone the repository with git clone inside your Debian VM. ⚠️ Use the SSH URL address, not HTTPS

    • 1️⃣.3️⃣ Inside the repository you will find different directories for each programming language (Default Languages are: Python, JavaScript, C#, Java, C++)

    • 1️⃣.4️⃣ Optionally create new branch into your repository called multiplication-table

    • 1️⃣.5️⃣ Choose your preferable programming language and open it's directory

    • 1️⃣.6️⃣ Create new file with name Your Name.Multiplication Table up to 10.<your programming language extension>

           ✅ Bonus points if you kept the right convention for naming the file for the programming language you chose
      
    • 1️⃣.7️⃣ Write a simple application which receives a single input -> integer between 1 and 10 and prints the multiplication table for the respective integer, each operation on a new line.

      ➡️ Example User input --> 1:

      1 x 1 = 1

      1 x 2 = 2

      1 x 3 = 3

      ...

           ✅ Bonus - Write a simple and easily understandable String messages for the inputs and output of your program.
      
           ✅ Bonus - Try to keep your code clean and simple. If your code consists of more than one file, separate your files in a sub-directory
      
           ✅ Bonus - Write additional IF-statements, e.g., what happens if the user enters char or double instead of integer.
      
           ✅ Bonus - Implement additional functionality to your program to print the entire multiplication table for the number from 1 to 10, instead for a specific integer.
      
           ✅ Bonus - Add comments to your program to explain your approach, add your name as author, etc. Be creative.
      
    • 1️⃣.8️⃣ After you are done, commit your changes to your repository

    • 1️⃣.9️⃣ Open your GitHub repository and check if your program has been uploaded in the correct directory.

    • 1️⃣.1️⃣0️⃣ Open a new Pull Request to merge your last modifications will the parent repository karastoyanov / linux-hobby-club.

            ⚠️ Open the pull-request from <your-repo> / <your-working-branch> to <development> branch of the parent repo.
            ✅ Bonus - Write clean and understandable Title and Description of the Pull Request. Include as much as possible details.
      

ℹ️ If the assignment is done properly, your pull request will be merged to the development branch of the parent repository.


Task 2 * ### 2️⃣