This assignment gives an insight into the basics of C and Python programming. The programming learned in C is used in arduino to run micro controller and further in project development.
Introduction to C:
Besides the classroom learning, I have referred http://learn.onlinegdb.com/learn_c_programming to learn more and practice online.
C Compiler converts program into a language understandable by a computer. The online C compiler I have used to practice is https://www.onlinegdb.com/online_c_compiler
Different elements of C programming are the valid character set, identifiers, keywords, basic data types and their representation, constants and variables.Download
Introduction to Python:
Learning of python can be found on https://www.w3schools.com/python/default.asp and online practice and compilation made on https://www.onlinegdb.com/online_python_interpreter
1.Use of while loop to write a number in descrending order:
Using C:
Using Python:
2.Programme to swap two variables:
Using C:
Using Python:
1. Write a program to take two integers "a" and "b" as inputs from the user and print their sum.
Using C:
Using Python:
2. Write a program to take an integer "n" as input and print if it is "odd" or "even".
Using C:
Using Python:
3. Write a program to take an integer "n" as input from the user and print its factorial.
Using C:
Using Python: