You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
title = {Chinese Internal Code Specification, National Standard Extended~{(GBK)}},
1037
+
type = {Technical Supervision Standard Letter},
1038
+
number = {1995~229},
1039
+
date = {1995-12-15},
1040
+
institution = {Standardization Department of the State Administration of Technical Supervision} # and # {Department of Science and Quality Supervision of the Ministry of Electronics Industry},
1041
+
address = l_china_beijing,
1042
+
}
1043
+
1044
+
@book{TUC2023U1510,
1045
+
title = {\pgls{unicode}\textsuperscript{\textregistered}~15.1.0},
author = a_virtanen_pauli # and # a_gommers_ralf # and # a_oliphant_travis_e # and # a_haberland_matt # and # a_reddy_tyler # and # a_cornapeau_david # and # a_burovski_evgeni # and # a_peterson_pearu # and # a_warren_weckesser # and # a_bright_jonathan # and # a_van_der_walt_stefan # and # a_brett_matthew # and # a_wilson_joshua # and # a_millman_jarrod_k # and # a_mayorov_nikolay # and # a_nelson_andrew_r_j # and # a_jones_eric # and # a_kern_robert # and # a_larson_eric # and # a_carey_cj # and # a_polat_ilhan # and # a_feng_yu # and # a_moore_eric_w # and # a_vanderplas_jake # and # a_laxalde_denis # and # a_perktold_josef # and # a_cimran_robert # and # a_henriksen_ian # and # a_quinter_ea # and # a_harris_charles_r # and # a_archibald_anne_m # and # a_ribeiro_antonio_h # and # a_pedregosa_fabian # and # a_van_mulbregt_paul # and # a_scipy_1,
986
1075
title = {\scipy~1.0:~Fundamental Algorithms for Scientific Computing in \python},
Copy file name to clipboardExpand all lines: notation/terms.sty
+43-1Lines changed: 43 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ text={\softwareStyle{C}},%
19
19
name={C},%
20
20
sort={C},%
21
21
description={%
22
-
is another programming language, which is very successful in system programming situations~\cite{ISOIEC207PLCWDOS,D2024MCFABAFITTCPL}.%
22
+
is another programming language, which is very successful in system programming situations~\cite{ISOIEC98892017PLCWDOS,D2024MCFABAFITTCPL}.%
23
23
}%
24
24
}%
25
25
%
@@ -35,6 +35,17 @@ See \cref{sec:howFloatingPointNumbersWork}.%
35
35
}%
36
36
%
37
37
%
38
+
\newglossaryentry{fstring}{%
39
+
name={f-string},%
40
+
plural={f-strings},%
41
+
sort={f-string},
42
+
description={%
43
+
is a special string in \python, which delimited by \pythonil{f"..."} which can contain expressions in curly braces like \pythonil{f"a\{6-1\}b"} that are then turned to text via \pgls{strinterpolation}, which turns the string to~\pythonil{"a5b"}. %
44
+
f\nobreakdash-strings are discussed in \cref{sec:fstrings}.%
45
+
}%
46
+
}%
47
+
%
48
+
%
38
49
\newglossaryentry{git}{%
39
50
name={Git},%
40
51
description={%
@@ -65,6 +76,17 @@ For this course, we recommend using \pycharm.%
65
76
}%
66
77
%
67
78
%
79
+
\newglossaryentry{strinterpolation}{%
80
+
name={(string) interpolation},%
81
+
sort={string interpolation},
82
+
description={%
83
+
In \python, string interpolation is the process where all the expressions in an \pgls{fstring} are evaluated and the final string is constructed. %
84
+
An example for string interpolation is turning \pythonil{f"Rounded \{1.234:.2f\}"} to \pythonil{"Rounded 1.23"}\pythonIdx{.2f}. %
85
+
This is discussed in \cref{sec:fstrings}.%
86
+
}%
87
+
}%
88
+
%
89
+
%
68
90
\newglossaryentry{Java}{%
69
91
text={\softwareStyle{Java}},%
70
92
name={Java},%
@@ -83,6 +105,16 @@ See \gls{significand}.%
83
105
}%
84
106
%
85
107
%
108
+
\newglossaryentry{modulodiv}{%
109
+
name={modulo division},%
110
+
description={%
111
+
is, in \python, done by the operator \pythonil{\%} that computes the remainder of a division. %
112
+
\pythonil{15 \% 6} gives us \pythonil{3}. %
113
+
Modulo division is mentioned in \cref{sec:int,sec:floatarith}.%
114
+
}%
115
+
}%
116
+
%
117
+
%
86
118
\newglossaryentry{significand}{%
87
119
name={significand},%
88
120
description={%
@@ -126,6 +158,16 @@ Under \ubuntu\ \linux, \ubuntuTerminal\ opens a terminal.%
126
158
}%
127
159
%
128
160
%
161
+
\newglossaryentry{unicode}{%
162
+
name={Unicode},%
163
+
description={%
164
+
A standard for assigning characters to numbers~\cite{TUC2023U1510,TUC2023U151ACS,ISOIEC106462020ITUCCSU}. %
165
+
The Unicode standard supports basically all characters from all languages that are currently in use, as well as many special symbols. %
166
+
It is the predominantly used way to represent characters in computers and is regularly updated and improved.%
Copy file name to clipboardExpand all lines: text/main/basics/simpleDataTypesAndOperations/float/float.tex
+2-1Lines changed: 2 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -69,6 +69,7 @@
69
69
\endhsection%
70
70
%
71
71
\hsection{Floating Point Arithmetic}%
72
+
\label{sec:floatarith}%
72
73
%
73
74
\begin{figure}%
74
75
\centering%
@@ -88,7 +89,7 @@
88
89
Thus, \pythonil{1.0 + 7}\pythonIdx{+} gives us \pythonil{8} and \pythonil{2 * 3.0}\pythonIdx{*} yields \pythonil{6.0}.
89
90
In other words, if one \pythonilIdx{float} occurs somewhere in an expression, it will \inQuotes{infect} everything that it touches to become a \pythonilIdx{float} too, even if the result could be represented as \pythonilIdx{int}.
90
91
Some results cannot be integers anyway, for example \pythonil{5 - 3.6}\pythonIdx{-} evaluates to~\pythonil{1.4}.
91
-
The remainder (the modulo) of a division can also be computed for floating point numbers.
92
+
The remainder (the \glsdisp{modulodiv}{modulo}) of a division can also be computed for floating point numbers.
92
93
The remainder of the division of 6.5 by 2, i.e., \expandafter\pythonil{6.5 \% 2}\pythonIdx{\%} is~\pythonil{0.5}.%
Copy file name to clipboardExpand all lines: text/main/basics/simpleDataTypesAndOperations/int/int.tex
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@
8
8
9
9
In many programming languages, there are different integer datatypes with different ranges.
10
10
In \pgls{Java}, a \pythonil{byte} is an integer datatype with range~\intRange{-2^7}{2^7-1}, a \pythonil{short} has range~\intRange{-2^{15}}{2^{17}-1}, an \pythonilIdx{int} has range~\intRange{-2^{31}}{2^{31}-1}, and \pythonil{long} has range~\intRange{-2^{63}}{2^{63}-1}, for example.
11
-
The draft for the \softwareStyle{C17} standard for the \pgls{C}~programming language lists five signed and five unsigned integer types, plus several ways to extend them~\cite{ISOIEC207PLCWDOS}.
11
+
The draft for the \softwareStyle{C17} standard for the \pgls{C}~programming language lists five signed and five unsigned integer types, plus several ways to extend them~\cite{ISOIEC98892017PLCWDOS}.
12
12
The different integer types of both languages have different ranges and sizes, and the programmer must carefully choose which she needs to use in which situation.
13
13
14
14
\python\ only has one integer type, called \pythonilIdx{int}.
@@ -18,7 +18,7 @@
18
18
%
19
19
\hsection{Integer Arithmetics}%
20
20
Now, what can we do with integer numbers?
21
-
We can add, subtract, multiply, divide, modulo divide, and raise them to powers.
21
+
We can add, subtract, multiply, divide, \glsdisp{modulodiv}{modulo divide}, and raise them to powers, for example.
22
22
23
23
\begin{figure}%
24
24
\centering%
@@ -57,7 +57,7 @@
57
57
Notice that the result of this division operator is always a floating point number, even if the number itself is an integer.
58
58
59
59
Now above we have said that \pythonil{33 // 4} yields the integer~\pythonil{8}.
60
-
The remainder of this operation can be computed using the modulo operator \expandafter\pythonilIdx{\%}, i.e., by typing \pythonil{33 \% 4}, which yields~\pythonil{1}.
60
+
The remainder of this operation can be computed using the \pgls{modulodiv} operator \expandafter\pythonilIdx{\%}, i.e., by typing \pythonil{33 \% 4}, which yields~\pythonil{1}.
61
61
We also find that \expandafter\pythonil{34 \% 4} yields~\pythonil{2}, \expandafter\pythonil{35 \% 4} gives us~\pythonil{3}, and \expandafter\pythonil{36 \% 4} is~\pythonil{0}.
0 commit comments