Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

bash iterate over a list

#!/bin/bash
StringVal="Welcome to linux"

for val in $StringVal; do
    echo $val
done

# Output: 
# Welcome
# to
# linux
Comment

PREVIOUS NEXT
Code Example
Shell :: install semantic ui react 
Shell :: github epitech 
Shell :: How to check the installed version of React-Native 
Shell :: convert to uppercase command awk 
Shell :: certbot enable nginx renew 
Shell :: heroku installation check 
Shell :: Installing qt ubuntu 
Shell :: ubuntu start nginx 
Shell :: install composer mac 
Shell :: show weather top bar in ubuntu 
Shell :: powershell check iso sha256sum 
Shell :: how to clear log files linux debian 
Shell :: how to clone my linux so all the installed packages 
Shell :: bash weather report 
Shell :: git stop tracking directory 
Shell :: tmux how to scroll in history 
Shell :: palindrome in shell script 
Shell :: os environ select defaut gpu 
Shell :: screen recorder linux 
Shell :: how to install yum on mac 
Shell :: ffmpeg rotate video 
Shell :: bash copy files but exclude some directories 
Shell :: ls | wc -l in other directory 
Shell :: pip installer for mac 
Shell :: vite react + eslint 
Shell :: how to clean pod in react native 
Shell :: heroku procfile laravel 
Shell :: powershell append to file 
Shell :: git discard all changes command 
Shell :: install iptables ubuntu 
ADD CONTENT
Topic
Content
Source link
Name
3+2 =