n8n.jpt.land: Added python-3-vs-python-2 impress presentation
							parent
							
								
									7d924a740e
								
							
						
					
					
						commit
						068da26712
					
				|  | @ -0,0 +1,124 @@ | |||
| 
 | ||||
| <html lang="en"> | ||||
| <meta charset="utf-8"> | ||||
| <meta content="width=device-width, initial-scale=1" name="viewport"> | ||||
| <meta content="upgrade-insecure-requests" http-equiv="Content-Security-Policy"> | ||||
| <title>Python 3 vs Python 2 Presentation</title> | ||||
| <style> | ||||
|   body { | ||||
|     background-color: #fff; | ||||
|     font-family: Arial, sans-serif; | ||||
|     color: #000; | ||||
|     margin: 0; | ||||
|     padding: 0; | ||||
|   } | ||||
|   .step { | ||||
|     width: 600px; | ||||
|     border-radius: 10px; | ||||
|     padding: 40px; | ||||
|     color: #333; | ||||
|     text-align: center; | ||||
|     opacity: 10%; | ||||
|     transition: opacity 1s; | ||||
|   } | ||||
|   .step img { | ||||
|     opacity: 0; | ||||
|     transition: opacity 1s; | ||||
|   } | ||||
|   .active { | ||||
|     opacity: 100%; | ||||
|     transition: opacity 1s; | ||||
|   } | ||||
|   .active img { | ||||
|     opacity: 100%; | ||||
|     transition: opacity 1s; | ||||
|   } | ||||
|   h1 { | ||||
|     font-size: 2.5em; | ||||
|     text-shadow: 2px 2px 4px rgba(0, 0, 0, .3); | ||||
|   } | ||||
|   p { | ||||
|     font-size: 1.2em; | ||||
|     line-height: 1.4; | ||||
|     margin: 20px 0; | ||||
|   } | ||||
|   img { | ||||
|     width: 80%; | ||||
|     height: auto; | ||||
|     margin-top: 20px; | ||||
|   } | ||||
| </style> | ||||
| <div id="impress"> | ||||
|   <!-- Introduction Slide --> | ||||
|   <div id="intro-slide" class="step" data-scale="1" data-x="0" data-y="0"> | ||||
|     <h1>Introduction to Python 3 vs Python 2 🐍</h1> | ||||
|     <p><strong>Python 2</strong> released in 2000; legacy code, no longer supported after 2020.</p> | ||||
|     <p><strong>Python 3</strong> introduced in 2008; the future of Python, ongoing support.</p> | ||||
|     <p>Key differences in syntax, libraries, and error handling.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Print Function Slide --> | ||||
|   <div id="print-function-slide" class="step" data-scale="1" data-x="1000" data-y="0"> | ||||
|     <h1>Print Function 🖨️</h1> | ||||
|     <p><strong>Python 2</strong>: Print statement <code>print "Hello, world"</code></p> | ||||
|     <p><strong>Python 3</strong>: Print function <code>print("Hello, world")</code></p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Integer Division Slide --> | ||||
|   <div id="integer-division-slide" class="step" data-scale="1" data-x="2000" data-y="0"> | ||||
|     <h1>Integer Division ➗</h1> | ||||
|     <p><strong>Python 2</strong>: Dividing two integers results in an integer. <code>3 / 2 = 1</code></p> | ||||
|     <p><strong>Python 3</strong>: Division results in a float. <code>3 / 2 = 1.5</code></p> | ||||
|     <p>Use <code>//</code> in Python 3 for integer division.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Unicode Support Slide --> | ||||
|   <div id="unicode-support-slide" class="step" data-scale="1" data-x="3000" data-y="0"> | ||||
|     <h1>Unicode Support 🌍</h1> | ||||
|     <p><strong>Python 2</strong>: Strings are ASCII by default.</p> | ||||
|     <p><strong>Python 3</strong>: Strings are Unicode by default.</p> | ||||
|     <p>Better support for non-English languages and symbols in Python 3.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Syntax Changes Slide --> | ||||
|   <div id="syntax-changes-slide" class="step" data-scale="1" data-x="4000" data-y="0"> | ||||
|     <h1>Syntax Changes 🔄</h1> | ||||
|     <p><strong>Python 2</strong>: <code>xrange()</code>, <code>print</code>, <code>except Exception, e:</code></p> | ||||
|     <p><strong>Python 3</strong>: <code>range()</code>, <code>print()</code>, <code>except Exception as e:</code></p> | ||||
|     <p>More intuitive and consistent syntax in Python 3.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Library Changes Slide --> | ||||
|   <div id="library-changes-slide" class="step" data-scale="1" data-x="5000" data-y="0"> | ||||
|     <h1>Library Changes 📚</h1> | ||||
|     <p><strong>Python 2</strong>: Libraries may not be compatible with Python 3.</p> | ||||
|     <p><strong>Python 3</strong>: A large number of Python 2 libraries have been updated or replaced.</p> | ||||
|     <p>Improved and more modern standard library in Python 3.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Error Handling Slide --> | ||||
|   <div id="error-handling-slide" class="step" data-scale="1" data-x="6000" data-y="0"> | ||||
|     <h1>Error Handling 🚫</h1> | ||||
|     <p><strong>Python 2</strong>: Less strict about mixing types (e.g., bytes/str).</p> | ||||
|     <p><strong>Python 3</strong>: Strict type checking, leading to fewer subtle bugs.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Conclusion Slide --> | ||||
|   <div id="conclusion-slide" class="step" data-scale="1" data-x="7000" data-y="0"> | ||||
|     <h1>Conclusion & Migration Tips 🎯</h1> | ||||
|     <p>Python 3 offers significant improvements and future-proofing.</p> | ||||
|     <p>Migrating from Python 2 to 3 requires careful consideration but is encouraged for long-term projects.</p> | ||||
|     <p>Use tools like <code>2to3</code> for code translation and testing.</p> | ||||
|   </div> | ||||
|    | ||||
|   <!-- Resources Slide --> | ||||
|   <div id="resources-slide" class="step" data-scale="1" data-x="8000" data-y="0"> | ||||
|     <h1>Resources & Further Reading 📖</h1> | ||||
|     <p>Python.org documentation</p> | ||||
|     <p>"Porting to Python 3" guide</p> | ||||
|     <p>Online tutorials and forums</p> | ||||
|   </div> | ||||
| </div> | ||||
| <script src="https://impress.github.io/impress.js/js/impress.js"></script> | ||||
| <script>impress().init()</script> | ||||
| 
 | ||||
		Loading…
	
		Reference in New Issue