How to install virtualbox on windows host
You can find many resources on the internet. Here's an example for installing virtualbox
application on a windows 10 host machine
https://www.youtube.com/watch?v=8mns5yqMfZk&ab_channel=ProgrammingKnowledge2
How to install ubuntu 20.04 on virtualbox
Here in this video you can find how to install ubuntu on your virtualbox
https://www.youtube.com/watch?v=x5MhydijWmc&list=TLPQMDQxMDIwMjCDsKD9OC8N
6g&index=2&ab_channel=ProgrammingKnowledge
The configuration (RAM, number of cores and size of your harddisk for ubuntu) depends on
your machine.
I'll provide you a more realistic one here:
M y PC (host machine) has 16 GB RAM, 4 cores, 1 TB of harddisk I configured my virtualbox
as below:
Please note that I use archlinux which is more lightweight compared to ubuntu. But these settings
should be enough for ubuntu as well.
How to install vim editor and clang compiler on
ubuntu
on ubuntu
open up a terminal and type
sudo apt install vim
to install vim
here's a quick video on how to do it
https://www.youtube.com/watch?v=ggIOhRKHWBE&ab_channel=ATOM
Similarly you can download clang compiler by
sudo apt install clang
Quick and dirty solution for coding
Until you set up your coding platform (I strongly suggest that you do it this week), you can use
the online C compiler:
https://repl.it/languages/c
Suggestions on coding platforms
You're free to use your favorite code editor/IDE for this class.
However, I'll make some suggestions:
I use a text-based editor for coding and I'll be using it when we're exercising during the lecture:
vim
For terminal, easy-to-use and customize:
terminology (has a bug on ubuntu, easy to fix)
IDE, I dont use an IDE but these are favored by many coders:
eclipse
CLion
code editor:
sublime
VSC (Visual Studio Code)
Making output window stay in Visual Studio
DO NOT conio.h and getch() to keep the output window open. This is a platform-bound
(windows) requirement. The functionality of this is to wait for an input from the user so that the
program is not finished. There are alternatives to keep the output window open.
1) Just use Ctrl+F5 instead of F5 to build, this will keep open the console since it cancels the
debugger.
2)To automatically close or keep open the console go to Tools->Options->Debugging-
>Automatically close the console when debugging stops.
Should we setup VisualStudio on linux or windows?
VisualStudio is for windows. If you're on linux please install CLion, eclipse or a text-based
editor like vim or emacs. You should also install a compiler suite, I recommended clang from
LLVM project for this.
Some sources for C programming exercises
Please find below some resources useful to exercise C programming
https://www.cprogramming.com/tutorial/c-tutorial.html?inl=nv
https://codeforwin.org/2015/05/basic-programming-practice-problems.html