16.12.2012 Views

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

|<br />

|<br />

|<br />

batch<br />

Exit Values<br />

Portability<br />

Related Information<br />

at, bg, crontab<br />

See Appendix F, “Localization” for more information.<br />

0 Successful completion<br />

>0 Returned if the command fails for any reason<br />

If an error occurs, batch does not schedule the job.<br />

P<strong>OS</strong>IX.2 User Portability Extension.<br />

bc — Use the arbitrary-precision arithmetic calculation language<br />

Format<br />

Description<br />

bc [–i] [–l] [file]<br />

bc is a programming language that can perform arithmetic calculations to arbitrary<br />

precision. You can use it interactively, by entering instructions from the terminal. It<br />

can also run programs taken from files.<br />

The file arguments you specify on the command line should be text files containing<br />

bc instructions. bc runs the instructions from those files, in the order that they<br />

appear on the command line, and then runs instructions from the standard input<br />

(stdin). bc ends when it runs a quit instruction or reaches the end of the file on<br />

stdin.<br />

bc is a simple but complete programming language with a syntax reminiscent of the<br />

C programming language. This version of bc is a superset of the standard language<br />

available on most systems. It has a number of additional features intended to make<br />

the language more flexible and useful. Features unique to this implementation are<br />

noted.<br />

Input consists of a series of instructions that assign values to variables or make<br />

calculations. It is also possible to define subprograms called functions, which<br />

perform a sequence of instructions to calculate a single value.<br />

bc displays the result of any line that calculates a value, but does not assign it to a<br />

variable. For example, the instruction:<br />

2+2<br />

displays:<br />

4<br />

By default, bc displays the result of any evaluated instruction followed by a newline.<br />

bc also saves the last value displayed in a special variable . (dot), so that you can<br />

use it in subsequent calculations.<br />

For a summary of the <strong>UNIX</strong>03 changes to this command, see Appendix N, “<strong>UNIX</strong><br />

shell commands changed for <strong>UNIX</strong>03.”<br />

50 z/<strong>OS</strong> <strong>V1R9.0</strong> <strong>UNIX</strong> <strong>System</strong> <strong>Services</strong> <strong>Command</strong> Reference

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!