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::iter; | |
| fn run_lengths<'a, T>(a: &'a[T]) -> impl Iterator<Item=usize> + 'a | |
| where | |
| T: std::cmp::PartialEq | |
| { | |
| a | |
| .windows(2) | |
| .enumerate() | |
| .filter_map(|(i, ab)| if ab[0]==ab[1] {None} else {Some(i as isize)}) |
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
| echo 'Doing stuff' |
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
| #!/usr/bin/env python2.7 | |
| """ | |
| Lectiolize: A python script for preparing files for upload to the Lectio system | |
| by adding student numbers to file names based on a reference folder. | |
| (C) janus@insignificancegalore.net, 2014 | |
| """ | |
| from collections import namedtuple | |
| import re |
NewerOlder