ZVON > References > Haskell reference
| Indexes | Syntax | Prelude | Ratio | Complex | Numeric | Ix | Array | List | Maybe | Char | Monad | IO | Directory | >> System << | Time | Locale | CPUTime | Random

Module: System
Function: getArgs
Type: IO [String]
Description: Computation getArgs returns a list of the program's command line arguments (not including the program name).
Related: getProgName

Example 1
Program source: 

import System

main = do x <- getArgs
          print x

Input: 1 3.3 AAA

Output: ["1","3.3","AAA"]

Example 2
Program source: 

import System

main = do x <- getArgs
	  print (sum (map rDouble x))

rDouble :: String -> Double
rDouble = read 

Input: 3.4 2 2.5

Output: 7.9




_____________________________________________
Reference Search | Sitemap | XML Glossary       ZVON | Systinet




Related sites:
  • dotNet Slackers - Your latest resource for ASP.NET
  • Dotnet Spider - Outsourcing and Offshore software development in India
  • XML - Xselerator, XSL Editor, BizTalk Utilities, XML Tutorials, Learn XML
  • Planet Source Code - The largest public source code database on the Internet
UNLIMITED Web Hosting by HostDepartment Alojamiento Web UK Domain Names glossary for conference call answering service
MSN VoIP Internettelefonie Hosted Exchange, SDSL VoIP Internettelefonie AT VoIP Internettelefonie DE