<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[The Quantum Observer - Medium]]></title>
        <description><![CDATA[On this site, you’ll find practical tutorials (networking, offensive security, programming), technology explainers, and broader reflections on how our tools reshape society and consciousness. - Medium]]></description>
        <link>https://medium.com/bitwise-tech-tips?source=rss----a67071dbe935---4</link>
        <image>
            <url>https://cdn-images-1.medium.com/proxy/1*TGH72Nnw24QL3iV9IOm4VA.png</url>
            <title>The Quantum Observer - Medium</title>
            <link>https://medium.com/bitwise-tech-tips?source=rss----a67071dbe935---4</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 12 Nov 2026 12:10:17 GMT</lastBuildDate>
        <atom:link href="https://medium.com/feed/bitwise-tech-tips" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to Install Tor on Kali Linux: A Step-by-Step Guide]]></title>
            <link>https://medium.com/bitwise-tech-tips/how-to-install-tor-on-kali-linux-a-step-by-step-guide-e41eba16e5f2?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/e41eba16e5f2</guid>
            <category><![CDATA[tor]]></category>
            <category><![CDATA[anonymity]]></category>
            <category><![CDATA[darkweb]]></category>
            <category><![CDATA[kali-linux]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Thu, 20 Jun 2024 20:22:52 GMT</pubDate>
            <atom:updated>2025-04-18T13:15:51.743Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/753/1*YetMndtPHjeQzTdgM_lCrA.png" /></figure><p>The Tor network is renowned for its ability to provide anonymity and privacy online. If you’re using Kali Linux, installing Tor can enhance your security toolkit by enabling you to browse the internet without revealing your identity or location. This tutorial will guide you through the process of installing Tor on Kali Linux and offer tips on staying safe while using it.</p><h4>What is Tor?</h4><p>Tor (The Onion Router) is free, open-source software that allows you to anonymize your internet traffic by routing it through a series of volunteer-operated servers around the world. This process, known as onion routing, ensures that your activity remains private and your location hidden.</p><h4>Step 1: Add the Tor Project Repository</h4><p>First, you need to add the Tor Project repository to your system. Open a terminal and run:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/489/1*TGpU1671FDk0fxAtL_arsQ.png" /></figure><p>Add the following line to the end of the file:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*9-MVW3ut8nPw6cbmloxyhg.png" /></figure><p>Save and close the file (Ctrl+O to save, Ctrl+X to exit).</p><h4>Step 2: Add the GPG Key</h4><p>Next, use this command to add the Tor Project’s GPG key to your keyring to authenticate the packages:</p><p><strong>curl </strong><a href="https://deb.torproject.org/torproject.org/gpgkey.asc"><strong>https://deb.torproject.org/torproject.org/gpgkey.asc</strong></a><strong> | sudo gpg — no-default-keyring — keyring /usr/share/keyrings/tor-archive-keyring.gpg — import</strong></p><h4>Step 3: Update the Package List</h4><p>Update your package list to include the new repository:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/449/1*6IjOfsDwVtkuydLtqNJbzg.png" /></figure><h4>Step 4: Install Tor</h4><p>Install Tor and the Tor Browser Launcher by running:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/454/1*nTspEYLIrElRW3ddTevk6g.png" /></figure><h4>Step 5: Start and Enable the Tor Service</h4><p>Start the Tor service:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/497/1*fJNyfyqtsodfx09GXU_wwQ.png" /></figure><p>Enable Tor to start on boot:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/428/1*7vJRmWNDl0r80NnWcaSqXg.png" /></figure><h4>Step 6: Verify the Installation</h4><p>Check if Tor is running by checking its status:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/424/1*xXoVQjfyLKkx6yCehNZRag.png" /></figure><p>You should see an output indicating that Tor is active and running.</p><h4>Step 7: Run Tor Browser</h4><p>To run the Tor Browser, use the Tor Browser Launcher:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/516/1*pxXg6gJWgWQjv-FYp57WzQ.png" /></figure><p>This command will download and install the latest version of the Tor Browser. After the installation, it will automatically start the Tor Browser.</p><h3>Tips for Staying Safe While Using Tor</h3><ol><li><strong>Avoid PII</strong>: Do not enter personally identifiable information while using Tor.</li><li><strong>Disable Plugins</strong>: Plugins like Flash and Java can bypass Tor and reveal your IP address.</li><li><strong>Use HTTPS</strong>: Always use websites with HTTPS to ensure your data is encrypted.</li><li><strong>Don’t Torrent</strong>: Avoid torrenting through Tor as it can expose your IP address.</li><li><strong>Regular Updates</strong>: Keep your Tor Browser updated to protect against vulnerabilities.</li></ol><p>By following this guide, you’ll be able to install and use Tor on Kali Linux effectively, enhancing your online privacy and security.</p><p>Master the basics of Networking, binary numbers and subnetting <a href="https://www.amazon.com/Mastering-Binary-Numbers-Subnetting-Comprehensive-ebook/dp/B0D9R7W257/ref=sr_1_1?crid=35ER42MZ1JBVX&amp;dib=eyJ2IjoiMSJ9.bA49KtFND_e_g4qEhuThUy6wYnlFK_u_4e47WKHBLIN9C2yOhWoJ05NzWoepuFKqjXwODkXzI9Y8YehP47GlW4-oeR7uL0-my7RPRfpeZtJbxXursiJGNl2bdlJbuhi1.X8_fsw514v0Ga_efGuxQyc20PsyITfGBRD5lfSGi8J4&amp;dib_tag=se&amp;keywords=mastering+binary+numbers&amp;qid=1743178076&amp;sprefix=mastering+binary+numbers%2Caps%2C185&amp;sr=8-1&amp;irclickid=zwTzT42m2xyPW6HVA0VoJw1jUks3bn3xy1hRTc0&amp;ref=dmm_asc_ir_4061861_zwTzT42m2xyPW6HVA0VoJw1jUks3bn3xy1hRTc0&amp;irgwc=1"><em>here</em></a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e41eba16e5f2" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/how-to-install-tor-on-kali-linux-a-step-by-step-guide-e41eba16e5f2">How to Install Tor on Kali Linux: A Step-by-Step Guide</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Understanding Python Arrays and Deques: A Comprehensive Tutorial]]></title>
            <link>https://medium.com/bitwise-tech-tips/understanding-python-arrays-and-deques-a-comprehensive-tutorial-007db6fa347a?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/007db6fa347a</guid>
            <category><![CDATA[arrays]]></category>
            <category><![CDATA[python-data-structures]]></category>
            <category><![CDATA[python-programming]]></category>
            <category><![CDATA[python3]]></category>
            <category><![CDATA[data-structures]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Mon, 17 Jun 2024 23:06:18 GMT</pubDate>
            <atom:updated>2024-06-17T23:06:18.110Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*psG3jaStDN6_mkMWXJpiJA.jpeg" /></figure><p>Python offers a range of data structures to handle different types of data efficiently. Among them, arrays and deques are two versatile structures that come in handy for various applications. This tutorial will guide you through the basics of Python arrays and deques, how to implement them, and best practices for efficient usage. Let’s get started!</p><h3>What is an Array?</h3><p>An array is a data structure that stores elements of the same type in a contiguous block of memory. In Python, arrays are not built-in like lists but can be implemented using the array module, which provides more efficient storage and operations for large volumes of data.</p><h4>Creating an Array</h4><p>To create an array in Python, you need to import the array module:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/542/1*pCsAxR3lULjtDSV8uEDoWA.png" /></figure><p>Here, &#39;i&#39; denotes the type of the array elements, where &#39;i&#39; stands for signed integer. Other type codes include:</p><ul><li>&#39;f&#39; for floating-point numbers</li><li>&#39;d&#39; for double-precision floating-point numbers</li><li>&#39;u&#39; for Unicode characters</li></ul><h4>Basic Array Operations</h4><ol><li><strong>Accessing Elements:</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/504/1*MPbsfclvHu95hNjBFrlG8g.png" /></figure><p>2. <strong>Appending Elements:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/504/1*1okmBsGi5ObN6zxpAW_pZA.png" /></figure><p>3. <strong>Inserting Elements:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/501/1*LD4RHX1iIBSNuYkM9IbYLw.png" /></figure><p>4. <strong>Removing Elements:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/504/1*AwHNS8g6xBNbhTgoq2YwAQ.png" /></figure><p>5. <strong>Pop Elements:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/503/1*fxIBDdV88haj--xyqPcDaw.png" /></figure><h3>What is a Deque?</h3><p>A deque (double-ended queue) is a data structure that allows you to add and remove elements from both ends efficiently. Deques are part of the collections module and are optimized for quick append and pop operations from both ends.</p><h4>Creating a Deque</h4><p>To create a deque, you need to import it from the collections module:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/536/1*L_wXxIkNJZ47--oB5Ppmww.png" /></figure><h4>Basic Deque Operations</h4><ol><li><strong>Appending Elements:</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/501/1*vzm7EQHsWY4tI414MM7VYA.png" /></figure><p>2. <strong>Popping Elements:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/505/1*UG5HHTFaG4tU9T5AoW499g.png" /></figure><p>3. <strong>Extending Deque:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/506/1*d5qtwsk5Pe90wVo2_Ex7-A.png" /></figure><p>4. <strong>Rotating Deque:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/506/1*crldOnj6K9Z3fwIwRkvqEw.png" /></figure><h3>Efficient Usage Tips</h3><p><strong>Choose the Right Data Structure:</strong></p><ul><li>Use arrays when you need efficient memory storage for homogeneous data and simple operations.</li><li>Use deques when you need fast append and pop operations from both ends.</li></ul><p><strong>Avoid Resizing:</strong></p><ul><li>Frequent resizing (e.g., appending to lists) can be costly. Deques handle resizing more efficiently than lists due to their underlying double-ended linked list structure.</li></ul><p><strong>Leverage Type Codes for Arrays:</strong></p><ul><li>Use appropriate type codes to optimize memory usage for arrays. For instance, use &#39;f&#39; for large arrays of floating-point numbers instead of lists.</li></ul><p><strong>Use List Comprehensions and Generators:</strong></p><ul><li>For constructing arrays or deques, consider using list comprehensions or generators to keep the code concise and readable.</li></ul><h3>Example Scenario: Implementing a Queue with Deque</h3><p>Let’s implement a simple queue using a deque:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/613/1*x_vDwdOipOr5tlV-v7OyvA.png" /></figure><h3>Conclusion</h3><p>Arrays and deques are powerful data structures in Python, each with its own strengths. Arrays are suitable for homogeneous data and memory efficiency, while deques provide fast operations at both ends. By understanding and leveraging these structures, you can write more efficient and effective Python code. Happy coding!</p><p>If you have any questions or need further clarification, feel free to leave a comment below!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=007db6fa347a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/understanding-python-arrays-and-deques-a-comprehensive-tutorial-007db6fa347a">Understanding Python Arrays and Deques: A Comprehensive Tutorial</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Understanding the OSI Model: A Comprehensive Guide]]></title>
            <link>https://medium.com/bitwise-tech-tips/understanding-the-osi-model-a-comprehensive-guide-99957a1d5419?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/99957a1d5419</guid>
            <category><![CDATA[osi-model]]></category>
            <category><![CDATA[computing]]></category>
            <category><![CDATA[comptia-network-plus]]></category>
            <category><![CDATA[computer-science]]></category>
            <category><![CDATA[network-engineering]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Thu, 13 Jun 2024 18:43:30 GMT</pubDate>
            <atom:updated>2024-07-28T20:05:09.859Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/753/1*oyZvElp5EhLh_n3KKkSEYQ.png" /></figure><p>The OSI (Open Systems Interconnection) model is a conceptual framework used to understand and implement network protocols in seven distinct layers. Each layer has specific functions and communicates with the layers directly above and below it. Let’s break down the OSI model using simple analogies to make it easier to understand.</p><h3>Overview of the OSI Model</h3><p>The OSI model is divided into seven layers:</p><ol><li><strong>Physical Layer</strong></li><li><strong>Data Link Layer</strong></li><li><strong>Network Layer</strong></li><li><strong>Transport Layer</strong></li><li><strong>Session Layer</strong></li><li><strong>Presentation Layer</strong></li><li><strong>Application Layer</strong></li></ol><p>Here’s a visual representation of the OSI model, in descending order starting with <strong>layer 7</strong>:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/709/1*rnOe8GSLlcfEckBWeHqHOA.png" /></figure><h3>Layer 1: Physical Layer</h3><p><strong>Analogy</strong>: Think of the physical layer as the roads and highways in a city. This layer is responsible for the physical connection between devices.</p><p><strong>Functions</strong>:</p><ul><li>Transmits raw bit streams over a physical medium (e.g., cables, radio frequencies).</li><li>Defines hardware standards for networking (e.g., cables, connectors).</li></ul><h3>Layer 2: Data Link Layer</h3><p><strong>Analogy</strong>: The data link layer is like the traffic lights and street signs that regulate traffic flow on the roads.</p><p><strong>Functions</strong>:</p><ul><li>Establishes and terminates a connection between two physically connected nodes.</li><li>Detects and possibly corrects errors that may occur in the physical layer.</li><li>Manages how data is framed and ensures data is sent to the correct destination (using MAC addresses).</li></ul><h3>Layer 3: Network Layer</h3><p><strong>Analogy</strong>: The network layer functions like a GPS system, which determines the best route for travel from one place to another.</p><p><strong>Functions</strong>:</p><ul><li>Determines the best physical path for data to travel from the source to the destination (using IP addresses).</li><li>Manages packet routing, forwarding, and addressing.</li></ul><h3>Layer 4: Transport Layer</h3><p><strong>Analogy</strong>: The transport layer is like a postal service that ensures packages are delivered reliably and in order.</p><p><strong>Functions</strong>:</p><ul><li>Provides end-to-end communication control and error checking.</li><li>Ensures complete data transfer (using TCP or UDP).</li><li>Manages flow control and data segmentation.</li></ul><h3>Layer 5: Session Layer</h3><p><strong>Analogy</strong>: The session layer acts like a phone call that establishes, manages, and terminates conversations.</p><p><strong>Functions</strong>:</p><ul><li>Establishes, manages, and terminates sessions between two communicating devices.</li><li>Controls the dialog between two devices, including session establishment, data exchange, and termination.</li></ul><h3>Layer 6: Presentation Layer</h3><p><strong>Analogy</strong>: The presentation layer is like a translator that converts data into a readable format for the recipient.</p><p><strong>Functions</strong>:</p><ul><li>Translates data between the application layer and the network.</li><li>Ensures data is in a usable format and performs encryption, decryption, and data compression.</li></ul><h3>Layer 7: Application Layer</h3><p><strong>Analogy</strong>: The application layer is like the various applications (e.g., email, web browsers) that users interact with on their devices.</p><p><strong>Functions</strong>:</p><ul><li>Provides network services directly to the user.</li><li>Facilitates communication between software applications and lower-layer network services.</li></ul><h3>Bringing It All Together</h3><p>To illustrate how data moves through the OSI model, let’s use an email as an example:</p><ol><li><strong>Application Layer</strong>: You compose an email in your email client (e.g., Gmail).</li><li><strong>Presentation Layer</strong>: The email client translates your email into a format suitable for transmission.</li><li><strong>Session Layer</strong>: The email client establishes a session with the email server.</li><li><strong>Transport Layer</strong>: The email is broken into packets, and the transport layer ensures these packets are sent reliably.</li><li><strong>Network Layer</strong>: Each packet is routed through the internet to the destination email server.</li><li><strong>Data Link Layer</strong>: The packets are framed and sent through different nodes and networks.</li><li><strong>Physical Layer</strong>: The bits are transmitted over the physical medium (e.g., fiber optics, wireless).</li></ol><p>When the email reaches the recipient, the process is reversed, and the email is reassembled and displayed in the recipient’s email client.</p><h3>Conclusion</h3><p>The OSI model is essential for understanding how different networking protocols interact and function. By breaking down network communication into these seven layers, it becomes easier to diagnose and troubleshoot network issues. Remembering each layer’s functions through analogies can make this complex model much more accessible and understandable.</p><p>Feel free to use these analogies and explanations to deepen your understanding of the OSI model, whether you are studying for an exam or trying to solve a network problem.</p><p>Learn more foundational concepts in Network Engineering <a href="https://www.amazon.com/Mastering-Binary-Numbers-Subnetting-Comprehensive-ebook/dp/B0D9R7W257/ref=sr_1_1?crid=3T4NXIU40EB49&amp;dib=eyJ2IjoiMSJ9.Cx_4GWFUXRv4p1wenbzPRZYI1kfSyLWnFIJ9MxWmMk6o-Gi50tq79xG2vRdA_kf3B-rmaoDbtCygcDBfHjKBoY4Q6JkzGwRpww6hUJfhtd95y0hgdUAcFwiz8PNdAzQP.C2HNjSVow9i7uEBw1aN9fnAckxitL37AXzwSuMsUZqc&amp;dib_tag=se&amp;keywords=mastering+binary+numbers&amp;qid=1722196675&amp;sprefix=mastering+bina%2Caps%2C162&amp;sr=8-1"><em>here</em></a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=99957a1d5419" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/understanding-the-osi-model-a-comprehensive-guide-99957a1d5419">Understanding the OSI Model: A Comprehensive Guide</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using Windows Event Viewer]]></title>
            <link>https://medium.com/bitwise-tech-tips/using-windows-event-viewer-ccc363622b4a?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/ccc363622b4a</guid>
            <category><![CDATA[windows-event-logs]]></category>
            <category><![CDATA[windows-10]]></category>
            <category><![CDATA[windows]]></category>
            <category><![CDATA[windows-11]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Wed, 12 Jun 2024 19:35:01 GMT</pubDate>
            <atom:updated>2024-06-12T19:35:01.452Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/749/1*gO0fxVkSLFM5T7kpv8W3GQ.png" /></figure><p>Windows Event Viewer is a powerful tool that allows users to view and analyze event logs on their system. These logs contain information about application, security, system, and setup events. This tutorial will guide you through the basics of accessing and using Event Viewer to troubleshoot issues.</p><h3>Step 1: Accessing Event Viewer</h3><h4><strong>Open Event Viewer:</strong></h4><ul><li>Press Win + X and select <strong>Event Viewer</strong> from the menu.</li><li>Alternatively, press Win + R, type eventvwr.msc, and press Enter.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/404/1*Uga4UevUitO2rlQhaGhABg.png" /></figure><h3>Step 2: Navigating Event Viewer</h3><p><strong>Event Viewer Interface:</strong></p><p>The left pane is the <strong>console tree</strong> with the following categories:</p><ul><li><strong>Custom Views</strong></li><li><strong>Windows Logs</strong></li><li><strong>Applications and Services Logs</strong></li><li><strong>Subscriptions</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/534/1*7ugp3xXG74dOpgisQ8s_xA.png" /></figure><p><strong>Common Logs:</strong></p><ul><li><strong>Application Log:</strong> Contains events logged by applications.</li><li><strong>Security Log:</strong> Contains security-related events.</li><li><strong>System Log:</strong> Contains events logged by the operating system.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/525/1*8flOsfbbONUOoTKIrNDZ4A.png" /></figure><h3>Step 3: Viewing Logs</h3><p><strong>Select a Log:</strong></p><p>Click on <strong>Windows Logs</strong> and choose <strong>Application</strong>, <strong>Security</strong>, or <strong>System</strong>.</p><p>I’ve selected the <strong>Application </strong>log:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JUtLMpWlglpU0yKtKeIseQ.png" /></figure><p><strong>Filter Events:</strong></p><ul><li>Right-click the log (e.g., System) and select <strong>Filter Current Log</strong>.</li><li>Use the <strong>Filter Current Log</strong> dialog to specify criteria, such as date range, event level (e.g., Error, Warning), and event source.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AAMrkQaylBLZUDm6zFMWZQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SOgDWyretM_rlwAgIAXnLA.png" /></figure><h3>Step 4: Analyzing Events</h3><p><strong>Event Details:</strong></p><ul><li>Click on an event to view its details.</li><li>The <strong>General</strong> tab provides a summary of the event.</li><li>The <strong>Details</strong> tab shows more technical information about said event.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qh6jGVSY4peFWxGyRuIa_Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5fXMw0M5G_l7e3AuF5HsOg.png" /></figure><p><strong>Event Levels:</strong></p><ul><li><strong>Information:</strong> Successful operations.</li><li><strong>Warning:</strong> Potential issues that do not affect system functionality.</li><li><strong>Error:</strong> Significant problems that may require attention.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/594/1*tlrG_AxUV08zLwxu9qDOBg.png" /></figure><h3>Step 5: Custom Views</h3><p><strong>Creating Custom Views:</strong></p><ul><li>Right-click <strong>Custom Views</strong> and select <strong>Create Custom View</strong>.</li><li>Configure filters based on your needs and save the view as <strong>New View</strong> (<em>You can name it whatever you like</em>).</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/377/1*7w9fXR7PkKmxzOY7dxANmw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/547/1*Z7blk28UCngBdsM1vof64Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/398/1*LLjXSeaOiFP7LFNXY0WutQ.png" /></figure><p><strong>Accessing Custom Views:</strong></p><p>Your custom views appear under <strong>Custom Views</strong> for easy access.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/599/1*p6k8YkVLE_mfuR23Eymw5w.png" /></figure><h3>Step 6: Exporting and Saving Logs</h3><p><strong>Saving a Log:</strong></p><ul><li>Right-click the log (e.g., System) and select <strong>Save All Events As</strong>.</li><li>Choose a location and save the file in the desired format (e.g., .evtx, .txt, .xml).</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*O2kjboupxBXvDTdoOLOLGg.png" /></figure><p>This can be a useful method for future troubleshooting or analysis.</p><p><strong>Exporting / Saving Logs:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/475/1*TMMjcNGqrydIkWOAwerSaA.png" /></figure><p>You can use exported logs for further analysis or to share with support teams.</p><h3>Conclusion</h3><p>Windows Event Viewer is an essential tool for monitoring and diagnosing system events. By understanding how to access, navigate, and analyze logs, you can effectively troubleshoot and maintain your Windows system.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ccc363622b4a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/using-windows-event-viewer-ccc363622b4a">Using Windows Event Viewer</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kali Linux: How to Fix, GUI Does Not Display at Login]]></title>
            <link>https://medium.com/bitwise-tech-tips/kali-linux-how-to-fix-gui-does-not-display-at-login-4324f11555b4?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/4324f11555b4</guid>
            <category><![CDATA[gui]]></category>
            <category><![CDATA[linux-terminal]]></category>
            <category><![CDATA[kali]]></category>
            <category><![CDATA[kali-linux]]></category>
            <category><![CDATA[linux-troubleshooting]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Tue, 11 Jun 2024 17:16:26 GMT</pubDate>
            <atom:updated>2024-06-11T17:16:26.554Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*yEIFeE65OcWAfjBso1Soow.jpeg" /></figure><p>When the GUI does not display at login on Kali Linux, there are several potential issues and corresponding solutions you can try to resolve the problem. Here are some steps you can follow to troubleshoot and fix the issue:</p><p><strong>Check Display Manager Status</strong>:</p><ul><li>Ensure that the display manager (e.g., gdm3, lightdm, or sddm) is running.</li><li>You can check the status of the display manager using the command:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/470/1*DxNEHKB9qmxSicS3OrzUUA.png" /></figure><ul><li>Replace gdm3 with lightdm or sddm if you are using a different display manager.</li><li>If it is not running, start it with:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/475/1*lF0gwS8ImeeV0Mg3QBl11Q.png" /></figure><p><strong>Reconfigure Display Manager</strong>:</p><ul><li>Reconfigure the display manager to ensure it is set up correctly.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/470/1*mPOku6iKfOfGpoAGN52SYw.png" /></figure><p>Again, replace gdm3 with your display manager if you are using a different one.</p><p><strong>Check Xorg Logs</strong>:</p><ul><li>Check the Xorg logs for any errors that might be preventing the GUI from starting.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/468/1*AU4u2AaL03yPbaXn1qyEbg.png" /></figure><ul><li>Look for lines marked with (EE) which indicate errors.</li></ul><p><strong>Check Disk Space</strong>:</p><ul><li>Ensure you have sufficient disk space, as a full disk can cause the GUI to fail to start.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/468/1*MheghZD_mMxXafD4roooAg.png" /></figure><p><strong>Update and Upgrade System</strong>:</p><ul><li>Update and upgrade your system to ensure all packages are up-to-date.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/470/1*ioyRkat3l2m7n4v-q7gFjg.png" /></figure><p><strong>Reinstall Display Manager and Desktop Environment</strong>:</p><ul><li>Reinstall your display manager and desktop environment to ensure they are correctly installed.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/462/1*-57qBB3ALvqQIIA5REbboA.png" /></figure><ul><li>Adjust the packages if you are using a different display manager or desktop environment.</li></ul><p><strong>Check .xinitrc and .xsession Errors</strong>:</p><ul><li>Sometimes, issues with .xinitrc or .xsession files in your home directory can cause problems.</li><li>Rename or delete these files to reset any custom configurations.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/468/1*KTnRLu3YHPyDnAFHX6z4Jw.png" /></figure><p><strong>Switch to a Different TTY</strong>:</p><ul><li>Press Ctrl + Alt + F1 to switch to a different TTY (you can use F1 to F6).</li><li>Log in and try restarting the display manager.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/461/1*EEbyAgQuYTOVpXAmO74g1g.png" /></figure><p><strong>Check GPU Drivers</strong>:</p><ul><li>Issues with GPU drivers can sometimes prevent the GUI from starting. Ensure that the appropriate drivers for your GPU are installed.</li><li>Example, For NVIDIA GPUs:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/460/1*OJodLqHpU70tjCtl-KAoNw.png" /></figure><p><strong>Check for Broken Packages</strong>:</p><ul><li>Sometimes broken packages can cause issues. Fix them using:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/466/1*3IOEfd7oux19AKDJLUiwww.png" /></figure><p>If none of these steps resolve the issue, it might be helpful to get more specific details about any error messages / codes you are seeing, or any recent changes you made to the system before the issue started occurring. This information can help narrow down the potential causes.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4324f11555b4" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/kali-linux-how-to-fix-gui-does-not-display-at-login-4324f11555b4">Kali Linux: How to Fix, GUI Does Not Display at Login</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kali Linux: How To Create And Delete Folders in Terminal]]></title>
            <link>https://medium.com/bitwise-tech-tips/kali-linux-how-to-create-and-delete-folders-in-terminal-8618b2355722?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/8618b2355722</guid>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[mkdir]]></category>
            <category><![CDATA[kali-linux]]></category>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[kali]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Mon, 10 Jun 2024 17:13:11 GMT</pubDate>
            <atom:updated>2024-06-10T17:13:11.418Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4tc7cvlXsIic5NIJJPW8Xw.jpeg" /></figure><p>Creating a folder (directory) using the terminal in Kali Linux is a straightforward process. You can use the mkdir command to accomplish this. Here&#39;s a step-by-step guide:</p><p><strong>Open the Terminal:</strong></p><p>You can open the terminal by clicking on the terminal icon in the taskbar or by pressing Ctrl + Alt + T.</p><p><strong>Navigate to the Desired Directory:</strong></p><p>Use the cd command to navigate to the directory where you want to create the new folder. For example, to navigate to the /home/username/Documents directory, you would use:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/573/1*aa5sZLv_x0mcm4DPKE31ig.png" /></figure><p>If you want to create the folder in your current directory, you can skip this step.</p><p><strong>Create the Folder:</strong></p><p>Use the mkdir command followed by the name of the folder you want to create. For example, to create a folder named new_folder, you would use:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/475/1*HwicHE083zjGa_P9yQ7JMQ.png" /></figure><p><strong>Verify the Folder Creation:</strong></p><p>You can use the ls command to list the contents of the directory and verify that the new folder has been created. For example:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/474/1*oEskLVeEAToWNpFn8o62-g.png" /></figure><p>Here is a summary of the commands:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/643/1*G6QUARWvb2bbv5n4uNKwhA.png" /></figure><h3>Example</h3><p>If you want to create a folder named Projects in your home directory, the commands would be:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/647/1*oPRHNCUfTY6MSvlt99NCBQ.png" /></figure><p>To delete a folder in the terminal on Kali Linux, you can use the rm command with the -r (recursive) option. This is necessary because rm by itself only removes files, not directories. Here&#39;s how you can do it:</p><p><strong>Open the terminal.</strong></p><p><strong>Navigate to the parent directory of the folder you want to delete.</strong> Use the cd command for this. For example, if the folder you want to delete is located in /home/user/Documents, you would navigate there by typing:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/509/1*-waK-xbuQjBOyy0VrqN8ug.png" /></figure><p><strong>Delete the folder.</strong> Use the rm -r command followed by the folder name. For example, to delete a folder named example_folder, you would type:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/508/1*sSoGhTtFISte541XF1lXjA.png" /></figure><p>If you want to avoid being prompted for confirmation for each file within the directory, you can add the -f (force) option:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/504/1*n53jxWJ84j9ENvsjTQ2vfw.png" /></figure><p><strong>Caution:</strong> The rm -rf command is very powerful and will permanently delete the specified folder and all of its contents without any confirmation. Be very careful when using it to avoid accidentally deleting important data.</p><p>Here is an example sequence:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/537/1*Er-gceydkuXXvC2zOqsD5w.png" /></figure><p>Replace /path/to/parent_directory with the actual path to the directory containing the folder you want to delete, and folder_to_delete with the name of the folder you want to delete.</p><p>That’s it! You’ve successfully both created and deleted a folder using the terminal in Kali Linux.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8618b2355722" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/kali-linux-how-to-create-and-delete-folders-in-terminal-8618b2355722">Kali Linux: How To Create And Delete Folders in Terminal</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kali Linux: Creating An Executable Script File]]></title>
            <link>https://medium.com/bitwise-tech-tips/kali-linux-creating-an-executable-script-file-ae674186ea91?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/ae674186ea91</guid>
            <category><![CDATA[kali]]></category>
            <category><![CDATA[kali-linux]]></category>
            <category><![CDATA[scripting]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[terminal]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Fri, 07 Jun 2024 20:27:57 GMT</pubDate>
            <atom:updated>2024-06-07T20:27:57.285Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/896/1*11rxMtvU-p2-NJYTsLyklQ.jpeg" /></figure><p>Creating a script file in the terminal in Kali Linux involves several steps, typically using text editors like nano, vi, or vim, and setting the necessary permissions. Here&#39;s a step-by-step guide to creating and running a basic shell script:</p><p><strong>Open the Terminal</strong>:</p><ul><li>You can open the terminal by clicking on the terminal icon or by pressing Ctrl + Alt + T.</li></ul><p><strong>Create a New Script File</strong>:</p><ul><li>Use a text editor to create a new file. Here, we’ll use nano for simplicity. You can replace nano with vi or vim if you prefer those editors.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/515/1*7xBePMICRcTZ6qEyt7jMcA.png" /></figure><p>This command opens the nano editor with a new file named myscript.sh.</p><p><strong>Write Your Script</strong>:</p><ul><li>In the nano editor, you can write your shell script. For example, you can start with a simple script that prints &quot;Hello, World!&quot;:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/503/1*8jRO9mvZe6xj3cl19PID8g.png" /></figure><ul><li>The #!/bin/bash line is called a shebang, and it tells the system that this script should be run using the Bash shell.</li></ul><p><strong>Save the Script and Exit the Editor</strong>:</p><ul><li>In nano, save the file by pressing Ctrl + O (then press Enter to confirm the filename), and exit by pressing Ctrl + X.</li></ul><p><strong>Make the Script Executable</strong>:</p><ul><li>Before running the script, you need to make it executable. Use the chmod command to change the file permissions:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/508/1*ln8mwVdANLEMSCFsHmdMtw.png" /></figure><p><strong>Run the Script</strong>:</p><ul><li>Now you can run your script by typing:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/506/1*HmH3n_2S5kHdEgZN_Pm6_A.png" /></figure><ul><li>You should see the output:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*pM18omS0Yi5WQ8xKNlcTcQ.png" /></figure><h3>Example: Creating and Running a Script</h3><p>Here’s a quick summary of the commands in sequence:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*KUXdPLWDSJiyZm_jPjWD_A.png" /></figure><p>By following these steps, you can create, edit, and execute a script file in the terminal on Kali Linux.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ae674186ea91" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/kali-linux-creating-an-executable-script-file-ae674186ea91">Kali Linux: Creating An Executable Script File</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Solve “unable to lock directory /var/lib/apt/lists/” Error for Kali Linux]]></title>
            <link>https://medium.com/bitwise-tech-tips/how-to-solve-unable-to-lock-directory-var-lib-apt-lists-error-for-kali-linux-115957402faa?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/115957402faa</guid>
            <category><![CDATA[apt]]></category>
            <category><![CDATA[kali]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[kali-linux]]></category>
            <category><![CDATA[shell]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Wed, 05 Jun 2024 18:15:50 GMT</pubDate>
            <atom:updated>2025-03-31T03:59:34.796Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/896/1*XsiycbGpgi199cv8d1mIpw.jpeg" /></figure><p>The error message “unable to lock directory /var/lib/apt/lists/” typically indicates that the apt package management system in a Debian-based Linux distribution (such as Ubuntu) is unable to obtain a lock on the specified directory. This usually happens for one of several reasons:</p><p><strong>Another Process is Using </strong><strong>apt</strong>: The most common cause is that another process (such as another instance of apt, apt-get, aptitude, or a GUI package manager) is currently using apt to perform updates or install packages. The apt system uses lock files to prevent multiple processes from making changes simultaneously, which could potentially corrupt the package database.</p><p><strong>Leftover Lock Files</strong>: Sometimes, if a previous apt process was terminated unexpectedly (e.g., due to a system crash or being forcefully killed), the lock file might not get removed, causing subsequent apt processes to believe that the lock is still in place.</p><p><strong>Insufficient Permissions</strong>: The user might not have the necessary permissions to access or modify the apt directories. This typically happens when trying to run apt commands without using sudo.</p><h3>Steps to Resolve the Issue</h3><p>Here are some steps you can take to resolve this issue:</p><h4>1. Check for Running apt Processes</h4><p>You can check if any apt processes are currently running with the following command:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/645/1*WgferzlIynAjyKSWbYGpgg.png" /></figure><p>If you see any apt processes running, wait for them to complete. If you determine that they are hung or you want to terminate them, you can use the kill command to stop them. For example:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/648/1*SIeGK46r1XHdg8v534ExlA.png" /></figure><p>Replace &lt;PID&gt; with the actual process ID of the apt process.</p><h4>2. Remove Lock Files</h4><p>If you are sure no other apt processes are running, you can manually remove the lock files:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/647/1*bRaa49PNFe5Ke6MJaK69Aw.png" /></figure><p>Removing these files will release the locks, allowing you to run apt commands again.</p><h4>3. Update Package Lists</h4><p>After removing any lock files, update your package lists to ensure your package database is up to date:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/648/1*2n04YdcOFCJ4HngDXZJOjA.png" /></figure><h4>4. Run apt Commands with sudo</h4><p>Ensure you have the necessary permissions by running apt commands with sudo. For example:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*pOJHSW-OX2zpJGkrs51mDg.png" /></figure><p>By following these steps, you should be able to resolve the “unable to lock directory /var/lib/apt/lists/” error and proceed with using the apt package manager.</p><p><strong>Master the basics of Networking, binary numbers and subnetting </strong><a href="https://www.amazon.com/Mastering-Binary-Numbers-Subnetting-Comprehensive-ebook/dp/B0D9R7W257/ref=sr_1_1?crid=35ER42MZ1JBVX&amp;dib=eyJ2IjoiMSJ9.bA49KtFND_e_g4qEhuThUy6wYnlFK_u_4e47WKHBLIN9C2yOhWoJ05NzWoepuFKqjXwODkXzI9Y8YehP47GlW4-oeR7uL0-my7RPRfpeZtJbxXursiJGNl2bdlJbuhi1.X8_fsw514v0Ga_efGuxQyc20PsyITfGBRD5lfSGi8J4&amp;dib_tag=se&amp;keywords=mastering+binary+numbers&amp;qid=1743178076&amp;sprefix=mastering+binary+numbers%2Caps%2C185&amp;sr=8-1&amp;irclickid=zwTzT42m2xyPW6HVA0VoJw1jUks3bn3xy1hRTc0&amp;ref=dmm_asc_ir_4061861_zwTzT42m2xyPW6HVA0VoJw1jUks3bn3xy1hRTc0&amp;irgwc=1"><strong><em>here</em></strong></a><strong>.</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=115957402faa" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/how-to-solve-unable-to-lock-directory-var-lib-apt-lists-error-for-kali-linux-115957402faa">How to Solve “unable to lock directory /var/lib/apt/lists/” Error for Kali Linux</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Data Structures — Part One]]></title>
            <link>https://medium.com/bitwise-tech-tips/data-structures-part-one-709130367?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/709130367</guid>
            <category><![CDATA[data-structures]]></category>
            <category><![CDATA[python-programming]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[cmd]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Wed, 12 Jul 2023 05:06:13 GMT</pubDate>
            <atom:updated>2024-06-07T20:42:32.638Z</atom:updated>
            <content:encoded><![CDATA[<h3>Data Structures — Part One</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NEBRni33MULjFPAJueCEzw.jpeg" /></figure><p>Welcome to the Data Structures tutorial! If you are joining me from my last post, <a href="https://medium.com/bitwise-tech-tips/introduction-to-python-programming-38ee81f96d80"><strong>Introduction to Programming With Python</strong></a>, I touched on data structures a tiny bit. Now we are going to expand upon this concept a bit more. Lets begin… In Python, there are to categories of data structures, primitive and non-primitive. An example of primitive data structures are stings, integers, float integers, and Booleans. We are also going to learn a few functions / methods that can be used to process these data types. Oh, almost forgot; if you haven’t already please go to this <a href="https://notepad-plus-plus.org/"><strong>link</strong></a><strong> </strong>and install <strong>notepad++</strong>. We will be using this text editor throughout the tutorial series.</p><h3>Strings</h3><p>Strings can be composed of letters, numbers or other characters surrounded by <strong>single </strong>or <strong>double quotation marks</strong>. Example: “12345678”, ‘12345678’, ‘This sentence is a string as well.’, “!@#$%^”. The key take away here is that any sequence of characters can be a string as long as you stick to the proper syntax of what a string is, the characters must be enclosed in either single or double quotations. Now lets us take a look at the various operations that can be performed on strings. Take a look at the image below and type the lines of code into notepad++:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nUr8r0JCDspuRmHDlIFeXA.png" /></figure><p>This operation is called <strong>concatenation</strong>, it joins two strings together as you will see. But first, create a new directory/folder in your Documents folder and name it<strong> PyFiles</strong>. Now save your new notepad++ code file as <strong>concate.py</strong> in the <strong>PyFiles</strong> folder. Once that is done, open your <strong>cmd.exe </strong>and type this command &gt;<strong>cd documents</strong> and press enter then type &gt; <strong>cd pyfiles</strong> and press enter once more <strong>(don’t worry about capitalization, Windows cmd.exe is not case sensitive</strong>); This will put you in the directory/folder you’ve just created. Finally in cmd.exe, type this command and hit enter: &gt;<strong>python concate.py</strong>. You should now see this output:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/933/1*qMybueXDBGXLv-d3vMpNXw.png" /></figure><p>This operation <strong>concatenates </strong>or <strong>combines </strong>two strings using the <strong>“+” </strong>operator; it’s a pretty straight forward process and pretty self-explanatory. Lets move on to another operation. After having done the above example, can you guess the output of this expression?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_Pv7ShKUmJPcQPdN5BGK5A.png" /></figure><p>Give up? Take a look below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/935/1*GUF0CZPDlG0x0f5r_924_A.png" /></figure><p>If you guessed that the statement would be printed to the console ten times, then congrats! Obviously it is the <strong>“*” </strong>operator that makes this possible. You can play around with this little program by following the steps above for creating and running the concate.py program. These operations, although handy and good to know, are quite simply boring. I think it’s time to take a look at something a bit more complex and interesting;<strong> String slicing</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VFvQxCcliALqkLuSj55AHA.png" /></figure><p>This is the results after running the program:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/625/1*sVeIXY4vAgcK2DqpRBpgng.png" /></figure><p>Here’s the breakdown:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*czpnc20KErK759Ao06hiQQ.png" /></figure><p>First, a little clarity on how computers count; <strong>All elements or items in a list be they letters, numbers or characters are counted starting with zero</strong>. In context of the figure above the letters in the string “<strong>Hello</strong>” are counted as 01234, where <strong>H is index position 0</strong>; <strong>e is index position 1</strong>;<strong> l is index position 2</strong> so on and so forth. So in <strong>Figure 1 </strong>the <strong>2</strong> in the square brackets is actually telling the computer to to slice the string at index position 1 which is the 2nd element in the string. We then print out what is left over. This coding technique is called <strong>slicing using range</strong>; i.e. using the<strong> index range</strong> of the the elements of a <strong>list</strong>, <strong>string</strong> or<strong> tuple</strong>. In the case of the “Hello” string, the range would be 0–4. How about we experiment a little. I know by now you’ve asked, what&#39;s the space behind the colon used for? Well lets see what happens when we place a <strong>4</strong> behind the colon:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Zpn-4NZzylVoBFzprczdSw.png" /></figure><p>Ok now lets take a look at the results:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/774/1*zsxroIsdn0rxgAl-EUmOxA.png" /></figure><p>Hmm, this time only the middle two elements was printed out. Here&#39;s what happened:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LM6hK7hmx7uFYCJugja9cw.png" /></figure><p>In other words, the first two elements in the string (<strong>He</strong>) will be “sliced” off; Then the computer will print out all elements left over except the last element, which is the <strong>o.</strong> This is a pretty handy little technique to know and one you will probably use often in your own coding projects. So far, we went over both slicing and concatenation using the string data type. Now its time for you to experiment using both techniques in a program of your design. <strong>Programming problem:</strong> Can you concatenate elements from different strings using only the indexes?</p><p>You now know how to slice and concatenate a string; But what if you want to find out how long a string is? This is where Python’s built-in <strong>len() </strong>function comes in. Take a look at the code snippet below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RBo3i1W0g2qywyYiohVEIQ.png" /></figure><p>As the figure states the <strong>len()</strong> function counts the items in a string, list or tuple and then returns the total of those items as you can see below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/696/1*eEw4_HmFsBHbaLhxSHxtqg.png" /></figure><p>Now I know what you’re thinking, I counted twenty characters, how did the function come up with twenty-four? The reason is the function also includes the spaces in the count. Even spaces in the string are valid characters, keep this in mind when you use this function on strings. Now we come to the burning question, why would I need to know the length of a string, list, or tuple? Well one reason is you can have a line of code execute x number of times for each character / item in a string using a for loop. We will talk more about for loops later on in the series. Lets take a quick look at two more functions.</p><p>If you need a string / word capitalize, Python has got you covered with the <strong>capitalize()</strong> function. You will call this function a little differently than the <strong>len()</strong> function:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZWb-xBYddcxc-bWzIib8rQ.png" /></figure><p>Once you start progressing in Python and programming in general, you will be using <strong>dot notation</strong> often in your own coding projects; Especially when you start writing complex programs that use classes. Don’t worry, we will go over the concept of classes later in this series. In the meantime, this is the output you should have once you run the program above:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/716/1*8Jg0_7qIedAk9c0M5g6Y1w.png" /></figure><p>There’s really nothing much to this program; however, the take aways are: 1) if you need to capitalize the first letter in a word, use Python’s built-in <strong>capitalize()</strong> function, and 2) The <strong>capitalize()</strong> function is called using <strong>dot notation</strong>.</p><p>There are many more <a href="https://www.w3schools.com/python/python_strings.asp"><strong>function&#39;s / methods</strong></a> you can use on strings, too many to list here and I want to keep this post short and sweet. On that note, we will take a look at one more useful string function, <strong>isdigit()</strong>. Take a look at the example below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rQV0D-mLsAieDTDZx1dtTQ.png" /></figure><p>As you can see, dot notation is used when invoking this method on an object.<strong> Note</strong>: variables are also called <strong>objects </strong>in Python; in fact almost everything is an object. We will learn more about objects later in the series. Moving on, after running the code above you should get this output below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/705/1*Nzrvo15J9hsXQdUmyhubCQ.png" /></figure><p>Our first variable returns <strong>True</strong>, it’s a string composed of digits. The second variable returns <strong>False</strong> because its a string composed of just letters. If any of the strings had a mix of both letter and digits, the function would return <strong>False</strong>. <strong>The isdigit()</strong> method is good for checking whether string data consist of digits or not. The opposite of this function is the <strong>isalpha()</strong> method, which checks for letters in strings. This is a perfect segue into our next three topics: Integers, floats and Boolean data types.</p><p>I will not go too deep into <strong>integers</strong> and<strong> floats</strong>; They’re very simple data type and if you have done any basic arithmetic, you already know most of the operations you can perform on them. Adding <strong>(+)</strong>, subtracting <strong>(-)</strong>, dividing <strong>(/)</strong> and multiplying <strong>(*)</strong> can all be done on integers in Python. The things to remember are: <em>1)</em> integers are whole numbers <strong>(… -4, -3,-2, -1, 0,1, 2, 3, 4….) </strong>and <em>2)</em> unlike strings, they’re expressed without quotation marks. Floats are really just integers expressed in decimal format <strong>(…-4.0, -3.0, -2.0, -1.0, 0, 1.0, 2.0, 3.0, 4.0…)</strong>. You can do all the basic mathematical operations on floats as you can integers as well; However, know that if you add, subtract, divide etc. a float to an integer <strong>the resulting output will be a float</strong>. If want more details on floats and integers, click <a href="https://www.w3schools.com/python/python_numbers.asp">here</a>. Now on to our final topic, Booleans.</p><p>Booleans come in two values, True and False, this is also comparative to the integers 1 and 0. They’re useful when you need to check if an expression is true or false in a <strong>comparison</strong>. Also, Booleans are useful in <strong>conditional expressions</strong>, example: <strong>if-statements</strong> which we will go over soon. For now, let us take a look at Booleans in action:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yWqQZPlWwklS0rBe_Qe0jA.png" /></figure><p><strong>Note: </strong>You will use “<strong>==</strong>” to see if two values are equal; a single “<strong>=</strong>” to set a value to a variable.</p><p>Here is the output:</p><p><strong>True</strong>, <strong>False</strong>, and <strong>False </strong>are the results after running this program. There is nothing much to say about this simple concept; The three expressions in the code example are comparing two values to one another, whether the values are <strong>greater-than</strong>, <strong>less-than</strong> or <strong>equal-to</strong>. Only one comparison, the greaterThan variable, evaluated to <strong>True</strong>; All the other variables evaluated to <strong>False. </strong>As a bonus, I will give you a glimpse into how a <strong>conditional expression</strong> is used in an <strong>if-statement</strong>. Type this into your code editor and save the file under any name you want, however, you can save the file as “<strong>bonus_code.py</strong>” to avoid confusion.</p><p>We are going to take a quick look at <strong>if statements</strong>; These statements allow you to create programs which can make simple to complex decisions. Bleow is an example of a basic decision making script:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hu6NMd68Dj1iJwY423fOzQ.png" /></figure><p>The conditional symbol <strong>“&gt;”(less than)</strong> is what allows the computer to make a less than or greater than decision based on the user’s input. Other conditional symbols include: <strong>“&lt;”(less than), “==”(equal to), “&lt;=”(less than or equal to), “&gt;=”(greater than or equal to), “!=”(not equal to)</strong>. We will dive into if-statements more later on in this series.</p><p>Once you run this program in cmd.exe, this will display to your console:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/795/1*xd08Gmym34jAE7yQIIEgZg.png" /></figure><p>You have programmed instructions which allowed your computer to make a decision, congrats! Although, the overall purpose of this tutorial is not to teach you about<strong> if-statements</strong> but to expose you to how <strong>conditional expressions</strong> can be used in programs.</p><p>We have now reached the end of this tutorial; I hope that it was clear, concise enough for you to learn something of value and put you on the course to being competent in Python / programming. This is just the beginning and we still have a long way to go; I will be there to guide you through your learning. Now go and experiment; be creative and most importantly have fun. Next week, I will continue this tutorial in <a href="https://clawshea.medium.com/data-structures-part-two-lists-366b033536e3"><strong><em>Data Structures — Part Two</em></strong></a>. In the mean time, practice what you have learned!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=709130367" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/data-structures-part-one-709130367">Data Structures — Part One</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Introduction to Python Programming]]></title>
            <link>https://medium.com/bitwise-tech-tips/introduction-to-python-programming-38ee81f96d80?source=rss----a67071dbe935---4</link>
            <guid isPermaLink="false">https://medium.com/p/38ee81f96d80</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[windows-10]]></category>
            <category><![CDATA[coding]]></category>
            <dc:creator><![CDATA[C. Oscar Lawshea]]></dc:creator>
            <pubDate>Mon, 24 Apr 2023 17:01:33 GMT</pubDate>
            <atom:updated>2024-06-10T20:36:50.975Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*psG3jaStDN6_mkMWXJpiJA.jpeg" /></figure><p>Welcome and congrats on taking your first steps to learning software coding. In this tutorial, you will learn the basics of programming using Python. This intro is not about just teaching you Python, its primary goal is to teach you the core concepts of programming which can be applied to all coding technologies. Since you are here, I assume you already have a goal in mind which programming will help you reach; whether it be an app you want to build or a tech career you want to pursue. Final word; throughout this journey there will be moments where you may become frustrated. Don’t be discouraged, learning to code is a roller-coaster ride of highs and lows. What’s most important is persistence and consistency; it may sometimes seem impossible but even a drop of water can punch a hole through solid stone over time. Let’s dive in…</p><p><strong>Note:</strong> <em>If you haven’t already, please take a look at my first post on </em><a href="https://medium.com/bitwise-tech-tips/installing-python-72c35ed976e4"><em>installing Python</em></a><em>.</em></p><p>What is programming / coding? Simply, you are writing a set of instructions for a computer to follow in order to complete a task. So, programmers / coders are instruction writers for computers…Boom, demystified. We are going to practice writing various kinds of instructions using Python syntax.</p><p>For your first program, we are going to write some simple code which will instruct the computer to print “Hello World!” Open up command prompt in administrator mode then type the command to open the Python shell:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*HzvvsB6DzpTMBc2LkQweqg.png" /></figure><p>Now, type:</p><p><strong>greeting = “Hello world!”</strong></p><p><strong>print(greeting)</strong></p><p>now press enter and you should get this output below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/935/1*tagz2y4doA5fYGWM-r5nZQ.png" /></figure><p>Pretty simple huh? Let’s break down what you have just written:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/1*dYFHnp2QzP-xOxUuZQvvHA.png" /></figure><p><strong>1.</strong> A <strong>string variable</strong> is a variable that “holds” a string data. A variable is a <strong>named </strong>unit which can be assigned a value; this value can change during the program’s execution hence the name. A programmer can name a variable anything he or she likes as long as the variable’s name describes the data / value type it “holds”. In our case, the <strong>greeting </strong>variable holds a <strong>string </strong>value / data type. As you see we named the variable <strong>greeting </strong>because this will give an indication to any programmer who reads your code what type of data this variable will contain.</p><p><strong>2.</strong> In Python and programming in general, you can recognize a <strong>string </strong>by any value surrounded by single or double <strong>quotation marks</strong> like the message our greeting variable holds in the image above, <strong>“Hello world!”.</strong></p><p><strong>Question: </strong>Is this, (“123456”), a string?</p><p><strong>Note: </strong>There are many different data types in Python besides string. Examples are <strong>integers</strong>(1, 2, 3,…), <strong>floating integers</strong>(1.0, 2.0, 3.0,…) and many <a href="https://www.w3schools.com/python/python_datatypes.asp"><strong>more</strong></a>.</p><p><strong>3. </strong>Print is a built-in Python <strong>function </strong>is a block of code that processes data when it is called; with our Hello world! program, the <strong>print()</strong> function was called on our <strong>greeting </strong>variable. The variable was then passed into the <strong>print()</strong> function as an <strong>argument </strong>and processed to output the message in our greeting. There are many built-in functions in Python; However by the end of this tutorial series, you will be able to define and create your own functions. Read more about Python functions <a href="https://www.w3schools.com/python/python_functions.asp"><strong>here</strong></a><strong> </strong>and <a href="https://www.w3schools.com/python/python_ref_functions.asp"><strong>here</strong></a>.</p><p><strong>Note:</strong> This program structure is called a <strong>Sequential Program</strong>; After you press enter, the execution of this code began at the <strong>greeting </strong>variable continuing down line by line until it reaches the final instruction line, which in our case is<strong> print()</strong>. Finally the output (your greeting) is displayed on the screen. This code structure is common in programming; when you start to read more code you will often see this structure throughout a program. It’s a very simple, straight forward coding method and the simplest on to learn.</p><p>So far, we have been using the shell to write and run basic code we will never need to use again. However, you will eventually write code (Functions, classes etc.) that you will want to use again in other programs. This is where code editors like <a href="https://notepad-plus-plus.org/"><strong>Notepad++</strong> </a>and IDE’s (Integrated Development Environments) like PyCharm. I will be doing examples of reusable code using Notepad++ in the next tutorial and throughout the series; You can still follow along with any tool you choose be it an IDE or Editor. This brings us to the end of this tutorial, I hope it was simple, useful and that you know understand what programming is and how the basics work. If you’re ready, head on over to the next tutorial; <a href="https://medium.com/bitwise-tech-tips/data-structures-part-one-709130367"><strong>Data Structures — Part One</strong></a></p><h3>Challenge</h3><p>Practice makes perfect, I challenge you to use the concepts you’ve just learned to print another message. Make the program as complex as you dare; use multiple variables to hold different messages then print them. <strong>Bonus: you can use commas to pass multiple arguments to the Print() function; Ex, print(varibale1, variable2).</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=38ee81f96d80" width="1" height="1" alt=""><hr><p><a href="https://medium.com/bitwise-tech-tips/introduction-to-python-programming-38ee81f96d80">Introduction to Python Programming</a> was originally published in <a href="https://medium.com/bitwise-tech-tips">The Quantum Observer</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>