#!/bin/bash input_file="large_file.txt" split -b 1M "$input_file" "split_file"string="you got a friend in me" IFS=' ' read -ra split <<< "$string" echo "${split[*]}" # Output: you got a friend in me echo "${split[3]}" # Output: friendIN="bla@some.com;john@home.com" arrIN=(${IN//;/ })#!/bin/bash # Define the string to be splitted string="Hello,World,How,Are,You" # Split the string using a delimiter (comma in this case) IFS=',' read -ra parts <<< "$string" # Print each part of the splitted string for part in "${parts[@]}"; do echo "$part" donetext="Hello,World,Devs" # Set comma as delimiter IFS=',' #Read the split words into an array based on comma delimiter read -a strarr <<< "$text" #Print the split words echo "index 0 : ${strarr[0]}" # Hello echo "index 1 : ${strarr[1]}" # World echo "index 2: ${strarr[2]}" # Devs