Skip to content

Instantly share code, notes, and snippets.

View maueroats's full-sized avatar

Mauer-Oats maueroats

View GitHub Profile
@maueroats
maueroats / ap-cs-framework-unit-1-feedback.md
Created June 13, 2023 15:38
Feedback on CSA Framework Unit 1

AP CS A Draft Framework Feedback

This document contains the comments from one detailed read-through of Unit 1 of the AP CS A Framework Draft. If you would like help understanding it or carefully reading the rest of the document, please contact Andrew Mauer-Oats (maueroats@gmail.com). I am a computer science teacher at Whitney M. Young Magnet High School in Chicago. At this point my document is not carefully proofread, but I hope it conveys the important ideas.

  • 1.4.A.1 System.out.print: including output is a change from the past. Why not stick with function return values? That would be "testable" (e.g. JUnit).
  • 1.4.B. String is a data type. It should be in 1.3. Having two definitions to arrive at "string literal" seems a waste. How about none, the way it is for double? Escape sequences are ok to include.
  • 1.4.C. There should be an analog for String expressions, at least mentioni
@maueroats
maueroats / join-previous-line.rkt
Last active January 16, 2024 16:13
Racket quickscript to join one line to the previous line.
#lang racket/base
;; This file is placed in the public domain.
;; Version 1.5 Added testable version. Now add space only when needed. Related bugs fixed.
;; Version 1.4 Remove duplicate source code from gist.
;; Version 1.3 Get characters directly, per suggestion of Laurent O.
;; Version 1.2 Suggestions by Laurent O: help, menu, url2script-info.
;; Version 1.0 Initial release.
;;
@maueroats
maueroats / commentary-typed-racket-issue-496.md
Last active June 29, 2020 20:39
Commentary on making the types of max, min require at least one argument

Types for Nonempty Lists

This is a writeup of the issues I found changing the type signatures of max and min to require at least one input. The idiom of applying these functions to "rest" args means a number of other type signatures need to be enhanced to propagate assurances that list are nonempty.

Discussion

@maueroats
maueroats / triangles.py
Created April 29, 2020 18:23
Python Triangulation Reader
from typing import TextIO
# Problem: produce the dual graph for a triangulation
## This file contains the triangle parsing code.
example_triangulation = '''
VERTICES 4
0.000000 240.000000 0.000000
(ql:quickload :lisp-unit)
(use-package :lisp-unit)
(setf *print-failures* t)
(defun one-more-mult (n)
"* Make sure you know how to use (mod x n) to figure out if x is
divisible by n. Write a function that takes in an integer and returns
true when the integer is one more than a multiple of 8."
nil)
@maueroats
maueroats / base-code.lisp
Created September 14, 2019 12:12
PAIP Ch 02 Starter Code
(declaim (optimize (debug 3)))
(ql:quickload :lisp-unit)
(use-package :lisp-unit)
(defparameter *print-failures* t)
(defun mappend (f xs)
(apply #'append
(mapcar f xs)))
(defun demo (x)
@maueroats
maueroats / keybase.md
Created March 28, 2019 00:43
Keybase.io proof of identity

Keybase proof

I hereby claim:

  • I am maueroats on github.
  • I am maueroats (https://keybase.io/maueroats) on keybase.
  • I have a public key ASBPwMX19TZWUx07wMbKOclCTxGAUw-LGo2N4UJ55zb88Qo

To claim this, I am signing this object: