Commit | Line | Data |
---|---|---|
82492b51 KB |
1 | C |
2 | C Copyright (c) 1980 The Regents of the University of California. | |
3 | C All rights reserved. | |
4 | C | |
ad787160 C |
5 | C This module is believed to contain source code proprietary to AT&T. |
6 | C Use and redistribution is subject to the Berkeley Software License | |
7 | C Agreement and your Software Agreement with AT&T (Western Electric). | |
82492b51 | 8 | C |
ad787160 | 9 | C @(#)argtst.f 5.2 (Berkeley) 4/12/91 |
82492b51 KB |
10 | C |
11 | ||
8385cd1b KB |
12 | character*16 arg, env |
13 | n = iargc() | |
14 | call getarg(0, arg) | |
15 | write(*,*) "name:", arg | |
16 | if (n .gt. 0) then | |
17 | do 100 i=1, n | |
18 | call getarg(i, arg) | |
19 | call getenv(arg, env) | |
20 | 100 write(*,*) i, arg, env | |
21 | endif | |
22 | end |