IT 116: Introduction to Scripting
Class 6

Tips and Examples


Review


New Material


Studying


Microphone

Quiz 1

I have posted the answers to Quiz 1 here.

Homework 3

I have posted homework 3 here.

It is due this coming Sunday at 11:59 PM.

Let's take a look at it.

Resources

The Resources page has links that you might find useful.

There is a link to it on the class web page.

Questions

Are there any questions before I begin?

Tips and Examples

Converting Decimal to Integer

Review

Performing Calculations

Decimal and Integer Division

Exponent Operator

Remainder Operator

Operator Precedence

Grouping with Parentheses

Mixed-Type Expressions and Data Type Conversion

Breaking Long Statements into Multiple Lines

Attendance

New Material

More Expressions inside Expressions

Whitespace Characters

Escape Sequences

Concatenation Operator

Concatenating Strings with Numbers

F-strings

Printing Numbers

Format Specifiers in F-strings

Using Format Specifiers with Scientific Notation

Using Format Specifiers to Put Commas in Big Numbers

Specifying Minimum Length for a Number

Alignment with the format Function

Formating Percentages

Order of F-string Designators

Don't Worry about F-strings

I will not ask you to use them on a quiz or exam.

I do not expect you to memorize all the different components of a format specifier.

These are the sorts of things you look up when you need them.

Studying

Class Exercise

Class Quiz