Set up test data
julia> bs = rand(Bool, 100000);
Using if/else:
julia> function foo(bs)
Set up test data
julia> bs = rand(Bool, 100000);
Using if/else:
julia> function foo(bs)
def deep_ls(path: str, max_depth=1): | |
""" | |
List all files and folders in specified path and | |
subfolders within maximum recursion depth. | |
""" | |
# List all files in path and apply sorting rules | |
li = mssparkutils.fs.ls(path) | |
# Return all files |
# https://vexx32.github.io/2018/10/26/Anonymous-Functions/ | |
function Retry() | |
{ | |
param( | |
[Parameter(Mandatory=$true)][Action]$action, | |
[Parameter(Mandatory=$false)][int]$maxAttempts = 3 | |
) | |
$attempts=1 |
#cloud-config | |
# Option 1 - Full installation using cURL | |
package_update: true | |
package_upgrade: true | |
groups: | |
- docker | |
system_info: |
#disgaea 4 | |
...What? | |
14 & Under | |
2 Second! | |
20 Hour Work Days | |
236+P | |
3 Chop Sticks | |
3 Color Pen | |
3 Hours to Live | |
3 Million HL |
a(state) { | |
state.x = 5; | |
} | |
b(state) { | |
out = state; | |
out.x = 5; | |
return out; |
#!/usr/bin/env bash | |
# https://developers.supportbee.com/blog/setting-up-cucumber-to-run-with-Chrome-on-Linux/ | |
# https://gist.github.com/curtismcmullan/7be1a8c1c841a9d8db2c | |
# https://stackoverflow.com/questions/10792403/how-do-i-get-chrome-working-with-selenium-using-php-webdriver | |
# https://stackoverflow.com/questions/26133486/how-to-specify-binary-path-for-remote-chromedriver-in-codeception | |
# https://stackoverflow.com/questions/40262682/how-to-run-selenium-3-x-with-chrome-driver-through-terminal | |
# https://askubuntu.com/questions/760085/how-do-you-install-google-chrome-on-ubuntu-16-04 | |
# Versions | |
CHROME_DRIVER_VERSION=`curl -sS https://chromedriver.storage.googleapis.com/LATEST_RELEASE` |
val a = 1 //> a : Int = 1 | |
val b = 2 //> b : Int = 2 | |
// Common mistakes with pattern matching | |
// the lower case variable pattern needs backwards quotes to work. | |
def oneOrTwo(i: Int): String = i match { | |
case `a` => "One!" | |
case `b` => "Two!" | |
} //> oneOrTwo: (i: Int)String |
#!/bin/sh | |
# before running this script, run the following command | |
# wget --save-cookies cookies.txt --post-data 'feed_id=****ID****&password=****PASS****' http://getpocket.com/login_process/ | |
i=1 | |
while [ $i -le 60 ] | |
do | |
wget --load-cookies cookies.txt -p http://getpocket.com/unread/$i | |
(( i++ )) |