what do u mean by $#,$* in unix programming?




Answers were Sorted based on User's Feedback



what do u mean by $#,$* in unix programming?..

Answer / vipul dalwala

$# - number of command line arguments or positional
parameters

$* - All of the positional parameters, seen as a single word

Is This Answer Correct ?    18 Yes 2 No

what do u mean by $#,$* in unix programming?..

Answer / narendrasairam

$# - Number of argument passed

$* - Array of arguments given (or) passed arguments as an array

Is This Answer Correct ?    9 Yes 0 No

what do u mean by $#,$* in unix programming?..

Answer / anita lohia

$# The number of command line argument
$* All the arguments on the command line

Is This Answer Correct ?    6 Yes 0 No




what do u mean by $#,$* in unix programming?..

Answer / siva prasad

$#- total no of positional parameters excluding the program
name
$*- all the arguments excluding the program name

Is This Answer Correct ?    3 Yes 0 No

what do u mean by $#,$* in unix programming?..

Answer / satyabrata

$# it contains the no of positional parameters
$* it contains all positional parameters as a single string

Is This Answer Correct ?    3 Yes 1 No

Post New Answer



More Shell Script Interview Questions

How do you print the output the same string which is typed in command line. how do you write the shell script or command for this. if i entered "Hello" in command line, it should print 'Hello', if i say "Hello Welcome", i should get the "Hello Welcome" as output.?

3 Answers   IBM, Symphony,


What are the different kinds of loops available in shell script?

3 Answers  


How to find duplicate record in file using shell script?

0 Answers   IBM, Wipro, Saama Tech,


How do I save a powershell script?

0 Answers  


How will you copy a file from one machine to other?

0 Answers  






how to separate the even and odd number generated from one file to two separate file i.e. even numbers in file1.txt and odd numbers in file2.txt

3 Answers   Infosys,


What are the two files of crontab command?

0 Answers  


write a shell script that accepts name from user and creates a directory by the path name, then creates a text file in that directory and stores in it, the data accepted from user till STOP, displays the no. of characters stored in the file.Program stops if directory name is null

1 Answers  


What is the lifespan of a variable inside a shell script?

0 Answers  


How Connect to a Database in Shell Programming?

4 Answers   Syntel,


What is batch file programming?

0 Answers  


Write a script to print the first 10 elements of fibonacci series.

0 Answers  






Categories