David C. · @d_k_bo
1 followers · 47 posts · Server social.tchncs.de
chfkch :nixos: :rust: · @chfkch
109 followers · 1597 posts · Server ruhr.social

@AstraKernel
I think it is B because v1 borrows v but the lifetime directly ends and v is free for v2 again.

#rustquiz #rustlang #rust #borrowchecker

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
1060 followers · 1380 posts · Server infosec.exchange

@chrisg
That's possibly the side effects of my series 😂. i set traps in that.

But in , I don't do. It will be simple 😉

#RustChallenge #rustquiz

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
1060 followers · 1378 posts · Server infosec.exchange

🦀

What is the result?

A. Prints Kernel
B. Compilation error
C. Runtime error

#rustquiz #rustlang #rust

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
1025 followers · 1294 posts · Server infosec.exchange

Will it compile? If so, How many times 💯 gets printed?

A. 1
B. 2
C. None
D. Compilation error(explain why)

#rustquiz #rustlang #rust

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
1023 followers · 1286 posts · Server infosec.exchange

explained

Ans: D

👉 We have declared tuples called `langs`

👉 In next line, we are doing destructuring the tuple

👉 ".." referred as partial destructuring helps to ignore some fields when destructuring

👉 Here `Rust` assigned to `l` and rest of the fields ignored

#rustquiz

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
1020 followers · 1274 posts · Server infosec.exchange

🦀

What is the output of this?

A. Error
B. RustJsPython
C. (Rust, Js, Python)
D. Rust

(Not hard/tricky or unique as , just simple quizzes)

#rustquiz #RustChallenge #rustlang #rust #rusttips #learnrust

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
999 followers · 1227 posts · Server infosec.exchange

🦀

What will be the outcome?

1. Both runs and gives the output

2. B gives output and A gives overflow error

3. A gives output and B gives error

4. Both gives error


Vote here 👇

#RustChallenge #rust #rustlang #rustquiz

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
999 followers · 1227 posts · Server infosec.exchange

What is the result?

A. Prints 1 (explain how)
B. Prints 2 (explain how)
C. Error (explain why)

Credits to @wcrichton(twitter)

#RustChallenge #rustlang #rustquiz #rust

Last updated 2 years ago

Astra Kernel :verified: · @AstraKernel
503 followers · 534 posts · Server infosec.exchange
Astra Kernel :verified: · @AstraKernel
503 followers · 534 posts · Server infosec.exchange
Astra Kernel :verified: · @AstraKernel
491 followers · 520 posts · Server infosec.exchange