for loop – POFTUT

Powershell ForEach Loop Statement Tutorial with Examples

ForEach is a PowerShell statement used to use iterate or loop over the given list, array or collection of the objects, strings, numbers, etc. ForEach is a very popular loop mechanism where we can use different cases like loop through files, Numbers, Strings, Processes, etc. Powershell version 4.0 brings some performance improvements to the ForEach loop. … Read more

While Loop In Java, Javascript, C++, C#, Python Programming Languages

While Loop In Java, Javascript, C++, C#, Python Programming Languages

Programming languages like Javascript, C++, C#, Python provides while loops in order to iterate over the given list, array, set etc. while loop is a very important part of the programming language because of its functionality. In this tutorial, we will examine and compare a while loop for programming languages like Javascript, C++, C#, and … Read more

How To Enumerate In Python Programming Language?

Python provides easy to use functions and mechanisms for programmers. While dealing with collection or list types we generally need some way to enumerate them. enumerate() function is used to create an iterable or enumerable type from the given list or collection. After this operation, we can use created object to iterate with for or while structures. … Read more

Linux Bash While Loop Tutorial with Examples

Linux Bash While Loop Tutorial with Examples

Linux bash provides a lot of mechanisms to make the system administrator’s life easier. These features are similar to the programming language features like variables, decisions, loops, etc. In this tutorial, we will look loops which can be implemented with for and while we have already examined for loops in the following tutorial. Bash For Loop Examples What … Read more

Bash Infinite Loop Shell Linux

How can write infinite shell that will run forever? May be I need a 5 second sleep between steps. Recently I have a issue with my routing table and I need to remove some route automatically every 5 minutes. I came up with a solution that runs every 4 minutes and clears unwanted routes. While … Read more