A new version of Python introduced in 2008 with a focus on eliminating redundancy in coding & providing a more user-friendly experience for new programmers.
- When diving two integers, we get an integral value in Python 2. Eg. 7/2 yields 3. - When diving two integers, we get a floating-point value in Python 3. Eg. 7/2 yields 3.5.
- In Python 2, exceptions are enclosed in notations using the keyword "except". - In Python 3, exceptions are enclosed within parentheses after the keyword "except".
- Python 2 has "xrange()" function to perform iterations over a range of numbers. - Python 3 introduces the "range()" function as an updated alternative to iterate over a range of numbers.