Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Getting started with Julia Programming Language

You're reading from   Getting started with Julia Programming Language Enter the exciting world of Julia, a high-performance language for technical computing

Arrow left icon
Product type Paperback
Published in Feb 2015
Publisher
ISBN-13 9781783284795
Length 214 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Ivo Balbaert Ivo Balbaert
Author Profile Icon Ivo Balbaert
Ivo Balbaert
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface The Rationale for Julia FREE CHAPTER 1. Installing the Julia Platform 2. Variables, Types, and Operations 3. Functions 4. Control Flow 5. Collection Types 6. More on Types, Methods, and Modules 7. Metaprogramming in Julia 8. I/O, Networking, and Parallel Computing 9. Running External Programs 10. The Standard Library and Packages A. List of Macros and Packages Index

Basic input and output

Julia's vision on input/output (I/O) is stream-oriented, that is, reading or writing streams of bytes. We will introduce different types of streams, such as file streams, in this chapter. Standard input (stdin) and standard output (stdout) are constants of the type TTY (an abbreviation for the old term, Teletype) that can be used in the Julia code to read from and write to (refer to the code in Chapter 8\io.jl):

  • read(STDIN, Char): This command waits for a character to be entered, and then returns that character; for example, when you type in J, this returns 'J'
  • write(STDOUT, "Julia"): This command types out Julia5 (the added 5 is the number of bytes in the output stream; it is not added if the command ends in a semicolon (;))

    STDIN and STDOUT are simply streams and can be replaced by any stream object in the read/write commands. readbytes is used to read a number of bytes from a stream into a vector:

  • readbytes(STDIN,3): This command waits for...
lock icon The rest of the chapter is locked
Visually different images
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Getting started with Julia Programming Language
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at ₹800/month. Cancel anytime
Modal Close icon
Modal Close icon