Talk:Environment variables: Difference between revisions

Line 8:
: You're making a requirement that isn't part of the task. You have a history of making up these requirements and changing task descriptions until they fit your understanding of them. I do rather wish you'd stop. [[User:CRGreathouse|CRGreathouse]] 08:13, 21 November 2011 (UTC)
 
::Take a look at most of the other examples and see if you do as they do. We do have to have some consistency of interpretation of the task goal to aid comparison; and yet tasks are written by different people, with different skills in writing descriptions. If everyone were to try and interpret the description differently then the resulting page would not aid language comparison. With so many examples here, and no demonstabledemonstrable 'extra' gained by the PARI/GP interpretation of the task goals, there is little reason to keep it, hence the comments. --[[User:Paddy3118|Paddy3118]] 08:29, 21 November 2011 (UTC)
::: a very brief look at the pari documentation gives the impression that there is no way to access environment variables directly. executing a system command seems to be the only way, however besides <code>system()</code> there is a function <code>extern()</code> which feeds the result back. i believe the following would satisfy the task:
<lang PARI/GP>print(extern("echo $HOME"))</lang>
::: though i am not sure if the syntax is correct.--[[User:EMBee|eMBee]] 12:07, 21 November 2011 (UTC)
 
Thanks EMBee. Looks good to me. CRGreathouse, if your amenable and could do a further checks that this is valid PARI/GP then this could form the basis of a better solution? --[[User:Paddy3118|Paddy3118]] 13:19, 21 November 2011 (UTC)
Anonymous user