The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 03-09-2009
srilaxmi srilaxmi is offline
Registered User
  
 

Join Date: Apr 2008
Posts: 22
Please explain the stmt

hi,

Please explain the below stmt.

P=1234
var1=:/a/b/c/file.dat

printf "%s %s\n" "$" "${var1#?}"


Output is:
1234 /a/b/c/file.dat

What is #? in printf stmt? by using that the first character( : ) of "var1" variable is not displayed in output. How is that? please explain..


Thanks,
Sri