top of page
Topic
Recent Posts
Archive
Tags
Bitwise operators
Before looking at Bitwise operators, we need to understand first Logical values vs. single bits. Logical operators take their arguments...
In honor of Lothar Collatz
In 1937, a German mathematician named Lothar Collatz formulated an intriguing hypothesis (it still remains unproven) which can be...
sqrt() and int()
sqrt() function is an inbuilt function in Python programming language that returns the square root of any number. Syntax: math.sqrt(x)...
For loops
Official definition: https://wiki.python.org/moin/ForLoop Picture source: https://www.python-course.eu/python3_loops.php for loops are...
String Methods
Python has a set of built-in methods that you can use on strings. Note: All string methods returns new values. They do not change the...
break and continue
break - exits the loop immediately, and unconditionally ends the loop's operation; the program begins to execute the nearest instruction...
sleep()
The sleep() function suspends (waits) execution of the current thread for a given number of seconds. Python has a module named time which...
Assignment Operators
Assignment operators are used in Python to assign values to variables. a = 5 is a simple assignment operator that assigns the value 5 on...
while i and for i in range ()
While Loop is used to repeat a block of code. Instead of running the code block once, It executes the code block multiple times until a...
Multi-line printing
You can use triple quotes to print strings on multiple lines in order to make text easier to read, or create a special text-based design....
bottom of page