Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Apress/beginning-rust-2e
/ functions
Functions
846 in github.com/Apress/beginning-rust-2e
⨍
Functions
846
◇
Types & classes
148
Function
f1
(n: i32)
Source Code/17-14.rs:4
Function
f1
()
Source Code/09-25.rs:9
Function
f2
(x: i32)
Source Code/09-14.rs:7
Function
f2
(x: Number)
Source Code/18-16.rs:6
Function
f2
(x: f32)
Source Code/18-15.rs:5
Function
f2
()
Source Code/09-25.rs:10
Function
f3
()
Source Code/09-25.rs:11
Function
f4
()
Source Code/09-25.rs:12
Function
f5
()
Source Code/09-25.rs:13
Method
fmt
(&self, f: &mut std::fmt::Formatter)
Source Code/19-24.rs:9
Method
from
(text: &str)
Source Code/20-19.rs:9
Method
from
(text: &str)
Source Code/20-23.rs:16
Method
from
(text: &str)
Source Code/20-17.rs:6
Method
from
(source: LargeNumber)
Source Code/20-15.rs:7
Method
from
(text: &str)
Source Code/20-21.rs:12
Method
from
(text: &str)
Source Code/20-18.rs:9
Method
from
(text: &str)
Source Code/20-20.rs:9
Method
from
(text: &str)
Source Code/20-22.rs:16
Method
from
(source: LargeNumber)
Source Code/20-14.rs:7
Method
from_re_im
(re: f64, im: f64)
Source Code/20-09.rs:9
Method
from_re_im
(re: Num, im: Num)
Source Code/20-10.rs:9
Function
g
(m: &'a u8)
Source Code/23-17.rs:7
Function
g
(a: T)
Source Code/19-10.rs:6
Function
get_name
(dict: &D, id: u32)
Source Code/19-29.rs:34
Function
get_name
(dict: &D, id: u32)
Source Code/19-28.rs:24
Function
get_name
( dict: &D, id: <D as Dictionary>::Key, //11 )
Source Code/19-30.rs:38
Function
get_third
(r: std::ops::Range<u32>)
Source Code/19-31.rs:4
Function
get_third
(s: &[f64])
Source Code/19-32.rs:4
Function
get_third
(mut iterator: Iter)
Source Code/19-33.rs:4
Function
h
(a: &T)
Source Code/19-10.rs:12
Method
im
(&self)
Source Code/20-09.rs:13
Method
im
(&self)
Source Code/20-10.rs:13
Function
incremented
(n: i32)
Source Code/17-15.rs:6
Method
is_not_visible
(&self)
Source Code/18-09.rs:13
Function
length
(s: &str)
Source Code/19-20.rs:4
Method
length
ILLEGAL: Inherent implementation for str type
Source Code/19-21.rs:6
Method
length
(&self)
Source Code/19-23.rs:8
Function
main
It prints nothing. */
Source Code/15-07.rs:3
Function
main
It may print: 0 0 800 801 801 1600 */
Source Code/12-13.rs:5
Function
main
It prints: 11 21 31 */
Source Code/16-11.rs:3
Function
main
ILLEGAL. The compiler prints the error message: cannot find function `f` in this scope */
Source Code/18-12.rs:4
Function
main
It prints: €: 8364 è: 232 e: 101 */
Source Code/16-04.rs:6
Function
main
It prints: 10*/
Source Code/03-31.rs:3
Function
main
It prints: true false; false true*/
Source Code/10-21.rs:3
Function
main
It prints: Error: Err. 2 Error: Err. 4 5 */
Source Code/17-11.rs:6
Function
main
It prints: "Hello" ['H', 'e', 'l', 'l', 'o'] */
Source Code/16-51.rs:5
Function
main
It prints: false*/
Source Code/03-21.rs:3
Function
main
ILLEGAL. The compiler prints the error message: attempt to use a non-constant value in a constant */
Source Code/06-31.rs:4
Function
main
ILLEGAL. The compiler prints the two error messages: cannot add `char` to `char` cannot add `bool` to `bool` */
Source Code/06-25.rs:5
Function
main
It prints: 0 [11, 22, 33, 44] [11, 22, 33, 44]*/
Source Code/15-26.rs:3
Function
main
It prints nothing. */
Source Code/11-02.rs:3
Function
main
It prints: NaN Nan*/
Source Code/19-14.rs:3
Function
main
It prints: Hello, [Hi]*/
Source Code/20-19.rs:3
Function
main
ILLEGAL. The compiler prints the error message: literal out of range for `i32` */
Source Code/06-15.rs:4
Function
main
It prints nothing. */
Source Code/03-13.rs:3
Function
main
It prints: Hello world*/
Source Code/17-16.rs:3
Function
main
It prints nothing. */
Source Code/06-12.rs:3
Function
main
It panics emitting the message: thread 'main' panicked at 'range end index 8 out of range for slice of length 5' */
Source Code/15-19.rs:4
Function
main
It prints: €: 8364 è: 232 e: 101 */
Source Code/16-03.rs:6
Function
main
ILLEGAL. The compiler prints the error message: missing lifetime specifier */
Source Code/24-12.rs:4
Function
main
It prints: 0 a, 1 b, 2 c, */
Source Code/16-31.rs:3
Function
main
Source Code/19-04.cpp:9
Function
main
It prints: 1 0 2 0 3 0 ... and so on, until the memory of the process is overflowed. Then, a runtime error message will be printed. */
Source Code/11-05.rs:8
Function
main
ILLEGAL. The compiler prints the error message: the trait bound `S: Clone` is not satisfied */
Source Code/22-27.rs:4
Function
main
It prints: -8 -31 */
Source Code/16-28.rs:3
Function
main
ILLEGAL. The compiler prints the error message: mismatched types */
Source Code/05-04.rs:4
Function
main
()
Source Code/10-12.rs:5
Function
main
It prints: [10, -8, 18, 0, -14, -2, 6, 10, 6, 2]*/
Source Code/09-32.rs:3
Function
main
It prints many lines. The first two lines are: 32: [ ] 33: [!] in the middle there are the four lines: 125: [}] 126: [~] 160: [ ] 161: [¡] and the las
Source Code/06-28.rs:13
Function
main
It prints: My number: 140*/
Source Code/01-10.rs:3
Function
main
It prints nothing. */
Source Code/22-24.rs:3
Function
main
It prints: 41 51 */
Source Code/16-12.rs:3
Function
main
()
Source Code/12-10.rs:4
Function
main
It prints: 12*/
Source Code/24-09.rs:3
Function
main
It prints: 1000, 1000000, 13500000000, 0.000012*/
Source Code/06-05.rs:3
Function
main
ILLEGAL. The compiler prints the error message: borrow of moved value: `a2` */
Source Code/05-35.rs:4
Function
main
It prints nothing. */
Source Code/03-25.rs:3
Function
main
It prints: 34.6*/
Source Code/09-13.rs:3
Function
main
It prints: These are three lines */
Source Code/02-16.rs:6
Function
main
It prints: 0, 1; None, Some(“Jane”)*/
Source Code/19-29.rs:3
Function
main
It prints: true 12300000 invalid float literal */
Source Code/17-20.rs:6
Function
main
It prints: 10 256*/
Source Code/06-02.rs:3
Function
main
It prints: Error: Err. 2 Error: Err. 4 5 */
Source Code/17-12.rs:6
Function
main
It prints: 15, 8, 4.*/
Source Code/05-18.rs:3
Function
main
It prints: As*/
Source Code/07-02.rs:3
Function
main
It prints nothing. */
Source Code/11-03.rs:3
Function
main
ILLEGAL. The compiler prints twice the error message: mismatched types For the first one, the explanation is: expected `i32`, found enum `T` For the s
Source Code/07-03.rs:8
Function
main
Source Code/23-04.c:6
Function
main
It prints: 226 130 172 195 168 101 */
Source Code/16-07.rs:3
Function
main
This program waits for the user to input a line. If you type: eè€ and then you press the Enter key, and then you type: Hello and then you press the En
Source Code/17-09.rs:10
Function
main
It waits for input. If the user types "b", and then presses Enter, the program prints: [Hi] If the user types something else or nothing, and then pres
Source Code/20-23.rs:10
Function
main
It prints: 45 4.5 true*/
Source Code/17-18.rs:3
Function
main
It prints: 132 -16 86 38 0 -62 */
Source Code/16-30.rs:3
Function
main
It prints nothing. */
Source Code/24-03.rs:3
Function
main
It prints: 48 35 20 39 42 33 50 29 27 18 17 16 13 12 */
Source Code/21-11.rs:3
Function
main
It prints: Hi*/
Source Code/14-06.rs:3
Function
main
ILLEGAL. The compiler prints the error message: can't capture dynamic environment in a fn item */
Source Code/13-03.rs:4
Function
main
It prints: 1 4 9 16 25 36 49 64 81 100 */
Source Code/04-16.rs:3
Function
main
The compiler prints the warning message: unreachable pattern Then, the program prints nothing. */
Source Code/07-13.rs:5
Function
main
It prints: None, Some(22)*/
Source Code/19-31.rs:3
← previous
next →
201–300 of 846, ranked by callers