This discussion is archived
1 Reply Latest reply: Jan 8, 2013 8:53 AM by user12619700 RSS

Syntax problems

983411 Newbie
Currently Being Moderated
Hi,
Can any body help me regarding the syntax

1) call getarg(integer,Character)

2) integer *4 :: variable=>123456789

With example will be more useful for me.

Regards
Vikrant
  • 1. Re: Syntax problems
    user12619700 Newbie
    Currently Being Moderated
    1) This is what we have in the man page for getarg()

    EXAMPLE
    demo% cat tesargs.f
    character argv*10
    integer i, iargc, m
    m = iargc()
    do i = 1, m
    call getarg ( i, argv )
    write( *, '( i2, 1x, a )' ) i, argv
    end do
    end
    demo % a.out first second last
    1 first
    2 second
    3 last


    2) I'm not exactly sure what you try to do, probably something like this ?

    demo% cat intdec.f90
    integer *4 :: variable=123456789
    print *, variable
    end
    demo% a.out
    123456789

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points