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
Learn Bosque Programming

You're reading from   Learn Bosque Programming Boost your productivity and software reliability with Microsoft's new open-source programming language

Arrow left icon
Product type Paperback
Published in Apr 2021
Publisher Packt
ISBN-13 9781839211973
Length 336 pages
Edition 1st Edition
Languages
Arrow right icon
Authors (2):
Arrow left icon
 Kaczmarek Kaczmarek
Author Profile Icon Kaczmarek
Kaczmarek
 Ibaceta Ibaceta
Author Profile Icon Ibaceta
Ibaceta
Arrow right icon
View More author details
Toc

Table of Contents (22) Chapters Close

Preface 1. Section 1: Introduction
2. Chapter 1: Exploring Bosque FREE CHAPTER 3. Chapter 2: Configuring the Bosque Environment 4. Chapter 3: Bosque Key Features 5. Section 2: The Bosque Language Overview
6. Chapter 4: Entrypoint Function 7. Chapter 5: Types and Operators 8. Chapter 6: Bosque Statements 9. Chapter 7: Project: Bosque in the Cloud 10. Section 3: Practicing Bosque
11. Chapter 8: Expressions in Bosque 12. Chapter 9: Collections 13. Chapter 10: Iterative Processing and Recursion 14. Chapter 11: Project: AI Classifier 15. Section 4: Exploring Advanced Features
16. Chapter 12: Namespaces, Concepts, and Entities 17. Chapter 13: Testing in Bosque 18. Chapter 14: Project: Path Optimizer 19. Other Books You May Enjoy Appendix A: Advanced Topics 1. Appendix B: What's Next in Bosque?

Writing a "Hello, World!" program

First things first: let's create a folder for our first program. You can do this directly from VSC or by using your favorite terminal. Since we have just set up our IDE to play with Bosque, I recommend that you use it. First, click File | New File. A new tab named Untitled-1 should appear—click File | Save (or press Ctrl + S on the keyboard) in order to rename it and save it at your desired location. Save the file under the name main.bsq. If you prefer to do this using a terminal, open it and type the following command:

$ mkdir first-project
$ cd first-project

Now, open VSC in the directory you have just created and create a file named main.bsq, as described earlier.

Once you have created the main.bsq file, fill it with the following content and save it:

namespace NSMain;
entrypoint function main(): String {
        return "Hello, world!";
}

I will explain this code...

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.
Learn Bosque Programming
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 $19.99/month. Cancel anytime
Modal Close icon
Modal Close icon