_getopt function

sir
can u tell me the windows/dos command in place of get_opt function..thanks in advance
Nikunj

nnikunji,
Windows/Dos commands? I think you are mistaken , this is a Unix Q&A Forum. How you want a windows command ?

This is a small definition of get_ops() function on Unix C
get_opt() - get options/arguments from command line argument list. The get_opt() function parses a command line argument list argv seeking for command arguments, option characters/strings and option arguments.
An option character is known if it has been specified in the string of accepted option characters, optstring . optstring may contain the following elements: individual characters, and characters followed by a colon to indicate an option argument is to follow. For example, an option string " x &qout; recognizes an option " -x ", and an option string "x:" recognizes an option and argument " -x argument ". If command argument is recognized get_opt() returns NULL , and optarg points to an argument. If known option character is recognized get_opt() returns option character itself and optarg points to an option argument, if it is anticipated. If current option character is unknown or if current option character demands argument but there is no anticipated argument or if option character is equal to '?' then return value is '?'. When the argument list is exhausted the get_opt() function returns an EOF . It's possible to check for long option by specifying correspondence between option character and option string optname using set_long_opt().