This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
choco install sudo -y | |
choco install GoogleChrome -y | |
choco install firefox -y | |
choco install git -y | |
choco install adobereader -y | |
choco install powertoys -y | |
choco install vscode -y | |
choco install slack -y | |
choco install discord -y | |
choco install steam -y |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Debugger entered--Lisp error: (quit) | |
read-string("GitHub password: " nil t nil) | |
#f(compiled-function (prompt &optional confirm default) "Read a password, prompting with PROMPT, and return it.\nIf optional CONFIRM is non-nil, read the password twice to make sure.\nOptional DEFAULT is a default password to use instead of empty input.\n\nThis function echoes `.' for each character that the user types.\nYou could let-bind `read-hide-char' to another hiding character, though.\n\nOnce the caller uses the password, it can erase the password\nby doing (clear-string STRING)." #<bytecode 0x400857bf>)("GitHub password: ") | |
apply(#f(compiled-function (prompt &optional confirm default) "Read a password, prompting with PROMPT, and return it.\nIf optional CONFIRM is non-nil, read the password twice to make sure.\nOptional DEFAULT is a default password to use instead of empty input.\n\nThis function echoes `.' for each character that the user types.\nYou could let-bind `read-hide-char' to another hiding character, thoug |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <math.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <sys/time.h> | |
//#define DEBUG | |
#define POWER 8 | |
#define MAX 256 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fn translate(source: &str) -> String { | |
let m = build_map(); | |
source | |
.to_lowercase() | |
.chars() | |
.filter(|c| c.is_alphanumeric()) | |
.map(|c| if c.is_numeric() { c } else { m[&c] }) | |
.collect::<Vec<char>>() | |
.chunks(5) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#lang racket | |
;; Generate a random list | |
;; n: list is length n | |
;; mx: maximum value to generate | |
(define (randomlist n mx) | |
(cond | |
[(= n 0) empty] | |
[else | |
(cons (+ 1 (random mx)) | |
(randomlist (- n 1) mx))])) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use std::f32; | |
use std::io::prelude::*; | |
fn main() { | |
print!("I need a float: "); | |
std::io::stdout().flush().ok().expect("Could not flush stdout"); | |
let stdin = std::io::stdin(); | |
let mut buf = String::new(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
class Monster { | |
public: | |
Monster(); | |
Monster(int initial_hp); | |
~Monster(); | |
void attack() const; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try { | |
Get-command -Name "git" -ErrorAction Stop >$null | |
Import-Module -Name "posh-git" -ErrorAction Stop >$null | |
$gitStatus = $true | |
} catch { | |
Write-Warning "Missing git support, install posh-git with 'Install-Module posh-git' and restart cmder." | |
$gitStatus = $false | |
} | |
function checkGit($Path) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void get_user_action(char input[MAX_INPUT_LENGTH]) | |
{ | |
bool validInput = false; | |
do | |
{ | |
cout << HAND_MSG << endl; | |
cin.get(input, MAX_INPUT_LENGTH, '\n'); | |
cin.ignore(100, '\n'); | |
s_to_lower(input); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[test] | |
fn telemetry_cleanup_removes_old_files() { | |
setup(&|config| { | |
expect_ok(config, &["rustup", "default", "stable"]); | |
expect_ok(config, &["rustup", "telemetry", "on"]); | |
expect_ok(config, &["rustc", "--version"]); | |
let telemetry_dir = config.rustupdir.join("telemetry"); | |
utils::ensure_dir_exists("telemetry", |
NewerOlder