---
title: "What is an infinite Loop? How is infinite loop declared?"  
description: "What is an infinite Loop? How is infinite loop declared?"  
author: "Aarav Maurya"  
published: 2017-12-20  
canonical: https://answers.mindstick.com/qa/31852/what-is-an-infinite-loop-how-is-infinite-loop-declared  
category: "technology"  
tags: ["java programming", "c#"]  
reading_time: 1 minute  

---

# What is an infinite Loop? How is infinite loop declared?

What is an [infinite](https://www.mindstick.com/forum/159435/react-app-crash-infinite-loop-identify-and-break) Loop? How is infinite loop declared?

## Answers

### Answer by Hemant Patel

An ***infinite loop*** is defined as ***it runs infinitely without any condition***. It can be broken by defining any **breaking logic** in the body of the statement blocks. Sometimes ***infinite loop*** also called ***Endless loop***. Its having lacks a functional exit so that is repeats indefinitely. Or in other words, it's a loop which will not have a termination. It will continue execution until you break it by defining any breaking logic in the body of the loop.You can integrate infinite loop as follows:

```
for( ; ; )
{
//Loop body
//Breaking logic for loop termination
}
```

***Hope it's informative...***\
\


---

Original Source: https://answers.mindstick.com/qa/31852/what-is-an-infinite-loop-how-is-infinite-loop-declared

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
