This file contains 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
import os,glob,string,time,sys | |
all_the_things = [] | |
class P: | |
def __init__(self,pid,name,swap): | |
self.pid = pid | |
self.name = name | |
self.swap = swap | |
def __repr__(self): | |
return str(self.pid) + " " + str(self.name) + " " + str(self.swap) |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="viewport" | |
content="user-scalable=no, width=device-width" /> | |
<style> | |
input { | |
border : 3px solid black; | |
padding : 2px; |
This file contains 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
--[[ | |
example of using | |
https://github.com/rxi/classic | |
]] | |
local Object = require("classic") | |
local Actor = Object:extend() -- new class |
This file contains 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
--[[ | |
example of using | |
https://github.com/rxi/classic | |
]] | |
local Object = require("classic") | |
local Actor = Object:extend() -- new class |
This file contains 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
import random | |
class Person: | |
def __init__(self,id): | |
self.amount = 100 | |
self.id = id | |
def __repr__(self): | |
return str(self.id) + " :: " + str(self.amount) | |
# setup |
This file contains 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 | |
(define (foo n) | |
(if (= (modulo n 2) 0) | |
(/ n 2) | |
(+ (* 3 n) 1) | |
)) | |
(define (goo a) |
This file contains 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 | |
(define a 10) | |
(module+ test | |
(require rackunit) | |
(check-equal? a 10 "making sure a is working") | |
) | |
This file contains 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 | |
(define nx 200) | |
(define ny 100) | |
(display (string-append "P3\n" | |
(number->string nx) " " | |
(number->string ny) "\n255\n")) | |
(for ([j (in-range (- ny 1) 0 -1)]) |
This file contains 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
proc readwholefile() = | |
let data = readFile("data.txt") | |
echo(data) | |
proc justoneline() = | |
let f = open("data.txt") | |
defer: f.close() | |
let firstline = f.readLine() | |
echo(firstline) |
This file contains 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
from selenium import webdriver | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.chrome.options import Options | |
mobile_emulation = { | |
"deviceMetrics": { | |
"width": 1440, "height": 3*1440, | |
"pixelRatio": 2.0 }, |