Search icon
Subscription
0
Cart icon
Close icon
You have no products in your basket yet
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Computer Programming for Absolute Beginners
Computer Programming for Absolute Beginners

Computer Programming for Absolute Beginners: Learn essential computer science concepts and coding techniques to kick-start your programming career

By Joakim Wassberg
$38.99
Full star icon Full star icon Full star icon Full star icon Empty star icon 4 (1 Ratings)
Book Jul 2020 430 pages 1st Edition
eBook
$26.99 $17.99
Print
$38.99
Subscription
$15.99 Monthly
eBook
$26.99 $17.99
Print
$38.99
Subscription
$15.99 Monthly

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Black & white paperback book shipped to your address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Buy Now
Estimated delivery fee Deliver to United States

Economy delivery 10 - 13 business days

Free $6.95

Premium delivery 6 - 9 business days

$21.95
(Includes tracking information)

Product Details


Publication date : Jul 31, 2020
Length 430 pages
Edition : 1st Edition
Language : English
ISBN-13 : 9781839216862
Category :
Table of content icon View table of contents Preview book icon Preview Book

Computer Programming for Absolute Beginners

Chapter 1: Introduction to Computer Programs

Programming is the art and science of writing instructions that a computer can follow to accomplish a task. This task can be playing a game, performing a calculation, or browsing the web, for example. However, before we can learn how to write programs, we should understand what a program is and how a computer can understand and execute the instructions we give it. In this chapter, we will study this in more detail, along with the basics of what a computer is, how it works, and its history.

Even a basic level of understanding of these topics will help us later on when we discuss the different aspects of writing programs, as we can then relate to how the computer will treat the code we write.

In this chapter, we will cover the following topics:

  • A perspective on the history and origins of the computer
  • Background knowledge of the original ideas behind programming
  • Understanding what a computer program is
  • Learning how...

A brief history of computing

Humans have always built tools and made innovations to make life more comfortable and to allow us to do more things faster and more efficiently. We need to go back in time a few hundred years in order to see the first attempts at building a tool that could resemble a computer. However, before we do that, we might want to define what a computer is. Wikipedia offers the following definition:

A computer is a machine that can be instructed to carry out sequences of arithmetic or logical operations automatically via computer programming.

So, a computer is a programmable machine that performs arithmetic or logical operations. Let's review a few inventions from the past using this definition to ascertain which of them could be considered a computer.

To begin, we can rule out the Jacquard machine, which was the automated loom invented in the early years of the 19th century. These looms could be programmed using punch cards, but they produced woven...

A brief history of programming

A programmable computer needs to be, well, programmed. So, of course, the history of programming goes hand in hand with the evolution of computers.

In 1833, Charles Babbage met Ada Lovelace, daughter of poet Lord Byron. She became very impressed and interested in Babbage's plans for his programmable machines, and their collaboration began. Among other things, she wrote some notes outlining her ideas for how the Babbage Analytical Engine could be programmed. We can call her the inventor of programming, even if we had to wait over 100 years until we had the machine that could make her ideas come true. Her status today is summarized in a History Extra article, from 2017, by James Essinger:

Today, Ada is quite rightly seen as an icon of feminist scientific achievement, a heroine of the mind, and one of the earliest visionaries in the early history of the computer.

In her notes, Lovelace did a couple of remarkable things. The first was that...

What is a program?

A computer is dumb in the sense that, without programs, it can't do anything. A computer program is a set of instructions that the computer can execute, and it is our job, as programmers, to write these programs using one or more programming languages.

Most applications that we run, such as a web browser, word processor, or mail client, can't communicate with the computer hardware directly. They require a layer in between that takes care of this. This layer is called the operating system. Windows and Linux are two examples of well-known operating systems. The main purpose of an operating system is to take care of the direct communication between the applications that we use and the hardware, such as the processor, memory, hard drives, keyboards, and printers. To be able to perform this communication, the operating system requires special programs that are designed to communicate with a particular device. These programs are called device drivers. A somewhat...

Understanding the binary system

Why is it that computers only work with zeros and ones? Why can't they work directly with text or images, for example? The answer is that it is rather easy to build circuits that can represent two states. If you have an electrical wire, you can either run electricity through it or not. The flow or no flow of electricity could represent several things, such as on or off, true or false, or zero or one. Let's think of these two states as zero and one for now, with zero representing no electricity flowing and one symbolizing that we do have flow. If we can serve these two states, we could add more wires and, by doing that, have more zeros and ones.

But what could we possibly do with all of these zeros and ones? Well, the answer is that we can do almost anything. For example, with only zeros and ones, we can represent any integer by using the binary numeral system. Let's demonstrate how that works.

To understand binary numbers, we must...

Summary

In this chapter, we have gone back in history and explored the development of computers. The history of computers is a vast topic, but we touched on some important events that have made computers the fantastic machines that we know today.

For a computer to be useful, it requires programs, and to be able to write programs, we need programming languages. We learned that the development of programming was closely related to the development of computers, even if Lady Ada Lovelace managed to write what was considered to be the first computer program about 100 years before the first computer was built.

With the history of computers covered, we then turned our attention to what a computer program is and how the computer can use the instructions given in the program to accomplish the intentions of the programmer. To do that, we examined the smallest parts of data a computer can handle, the bits, which are the zeros and ones of the binary representation of numbers. We learned...

Left arrow icon Right arrow icon

Key benefits

  • Understand the fundamentals of a computer program and apply the concepts you learn to different programming languages
  • Gain the confidence to write your first computer program
  • Explore tips, techniques, and best practices to start coding like a professional programmer

Description

Learning how to code has many advantages, and gaining the right programming skills can have a massive impact on what you can do with your current skill set and the way you advance in your career. This book will be your guide to learning computer programming easily, helping you overcome the difficulties in understanding the major constructs in any mainstream programming language. Computer Programming for Absolute Beginners starts by taking you through the building blocks of any programming language with thorough explanations and relevant examples in pseudocode. You'll understand the relationship between computer programs and programming languages and how code is executed on the computer. The book then focuses on the different types of applications that you can create with your programming knowledge. You'll delve into programming constructs, learning all about statements, operators, variables, and data types. As you advance, you'll see how to control the flow of your programs using control structures and reuse your code using functions. Finally, you'll explore best practices that will help you write code like a pro. By the end of this book, you'll be prepared to learn any programming language and take control of your career by adding coding to your skill set.

What you will learn

Get to grips with basic programming language concepts such as variables, loops, selection and functions Understand what a program is and how the computer executes it Explore different programming languages and learn about the relationship between source code and executable code Solve problems using various paradigms such as procedural programming, object oriented programming, and functional programming Write high-quality code using several coding conventions and best practices Become well-versed with how to track and fix bugs in your programs

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Black & white paperback book shipped to your address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Buy Now
Estimated delivery fee Deliver to United States

Economy delivery 10 - 13 business days

Free $6.95

Premium delivery 6 - 9 business days

$21.95
(Includes tracking information)

Product Details


Publication date : Jul 31, 2020
Length 430 pages
Edition : 1st Edition
Language : English
ISBN-13 : 9781839216862
Category :

Table of Contents

19 Chapters
Preface Chevron down icon Chevron up icon
1. Section 1: Introduction to Computer Programs and Computer Programming Chevron down icon Chevron up icon
2. Chapter 1: Introduction to Computer Programs Chevron down icon Chevron up icon
3. Chapter 2: Introduction to Programming Languages Chevron down icon Chevron up icon
4. Chapter 3: Types of Applications Chevron down icon Chevron up icon
5. Chapter 4: Software Projects and How We Organize Our Code Chevron down icon Chevron up icon
6. Section 2: Constructs of a Programming Language Chevron down icon Chevron up icon
7. Chapter 5: Sequence – The Basic Building Block of a Computer Program Chevron down icon Chevron up icon
8. Chapter 6: Working with Data – Variables Chevron down icon Chevron up icon
9. Chapter 7: Program Control Structures Chevron down icon Chevron up icon
10. Chapter 8: Understanding Functions Chevron down icon Chevron up icon
11. Chapter 9: When Things Go Wrong – Bugs and Exceptions Chevron down icon Chevron up icon
12. Chapter 10: Programming Paradigms Chevron down icon Chevron up icon
13. Chapter 11: Programming Tools and Methodologies Chevron down icon Chevron up icon
14. Section 3: Best Practices for Writing High-Quality Code Chevron down icon Chevron up icon
15. Chapter 12: Code Quality Chevron down icon Chevron up icon
16. Other Books You May Enjoy Chevron down icon Chevron up icon
Appendix A: How to Translate the Pseudocode into Real Code Chevron down icon Chevron up icon
1. Appendix B: Dictionary Chevron down icon Chevron up icon

Customer reviews

Filter icon Filter
Top Reviews
Rating distribution
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
(1 Ratings)
5 star 0%
4 star 100%
3 star 0%
2 star 0%
1 star 0%

Filter reviews by


Jerry Metcalf Dec 7, 2023
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
Well written and understandble
Feefo Verified review Feefo image
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela