---
title: "Discussion on \"The else Suite in Python that nobody told me about (it's not just for if)\" | Hashnode"
description: "Discussion on \"The else Suite in Python that nobody told me about (it's not just for if)\". The else clause in Python isn't just for if statements — it can also work with while loops. Here's what I learned about this misunderstood feature"
url: "https://hashnode.com/posts/the-else-suite-in-python-that-nobody-told-me-about-it-s-not-just-for-if/6a38666e82708bcf442f0f7b"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [The else Suite in Python that nobody told me about (it's not just for if)](https://buggleboy.hashnode.dev/the-else-suite-in-python-that-nobody-told-me-about-it-s-not-just-for-if?utm_source=hashnode&utm_medium=feed)

The else clause in Python isn't just for if statements — it can also work with while loops. Here's what I learned about this misunderstood feature

Jun 21 · 4 min read · buggleboy.hashnode.dev  
Read the article

-   [#python-programming](https://hashnode.com/tag/python-programming)
-   [#loops-in-python](https://hashnode.com/tag/loops-in-python)

## Written by

[Sandeep](https://hashnode.com/@buggleboy)

@buggleboy · Montreal, Canada

  
[View profile](https://hashnode.com/@buggleboy)

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
