Onion addresses
Search
News and Journalism
Onion addresses
Search
News and Journalism
| #!/bin/bash | |
| # Function to print the multimedia key table | |
| print_multimedia_table() { | |
| echo "+------------------------------------------------+" | |
| echo "| Win system key combination |" | |
| echo "+------------------------------------------------+" | |
| echo "| Multimedia function keys must be pressed with |" | |
| echo "| the FN+CTRL key combination |" | |
| echo "| (Ice blue light appears underneath the FN |" |
| from itertools import chain, repeat | |
| # Define the inventory as a dictionary | |
| inventory = { | |
| "banana": 3, | |
| "apple": 2, | |
| "pear": 1, | |
| "berry": 4, | |
| } |
| use std::time::Instant; | |
| fn main() { | |
| let iterations = 1_000_000; | |
| let mut odd_count = 0; | |
| // Using modulus | |
| let start_modulus = Instant::now(); | |
| for i in 0..iterations { | |
| if i % 2 != 0 { |
| <div class="block content has-background-light p-4"> | |
| <strong>Discussions around the web:</strong> | |
| <div id="comment" data-discussion-url="https://www.joelonsoftware.com/2000/04/06/things-you-should-never-do-part-i"> | |
| <ul></ul> | |
| </div> | |
| <p class="pt-2">Powered by <a href="https://discu.eu">discu.eu</a>.</p> | |
| </div> |
| mod domain { | |
| use std::{fmt::Display, ops::Deref}; | |
| #[derive(Debug)] | |
| pub enum DomainError { | |
| InvalidEmailAddress, | |
| InvalidResponseCode, | |
| } | |
| #[derive(Clone, PartialEq)] |
| struct Point { | |
| x: usize, | |
| y: usize | |
| } |
| mod domain { | |
| use std::ops::Deref; | |
| pub struct ViewCount { value: usize } | |
| impl ViewCount { | |
| pub fn new(value: usize) -> Self { | |
| Self { value } | |
| } | |
| } |
| mod domain { | |
| pub struct ViewCount { | |
| value: usize, | |
| } | |
| impl ViewCount { | |
| pub fn new(value: usize) -> Self { | |
| Self { value } | |
| } | |
| pub fn value(&self) -> usize { | |
| self.value |
| impl PageSize { | |
| pub fn new_from_kilobytes(value: usize) -> Result<Self, DomainError> { | |
| Ok(Self { value }) | |
| } | |
| pub fn as_bytes(&self) -> usize { | |
| &self.value / 1_000 | |
| } | |
| pub fn as_kilobytes(&self) -> usize { | |
| self.value | |
| } |