I was given a task to write script that works similar to "which" command in terminal. Here is what I already wrote:
#! /bin/bash
FILE=$1
for i in $PATH 
do 
if [[ "$i" -eq "FILE" ]] 
then 
echo …
Here I need to get a full path to a file that has been found. How could i get it? Thanks in advice.
 
    