Skip to content

Instantly share code, notes, and snippets.

View sbromberger's full-sized avatar

Seth Bromberger sbromberger

View GitHub Profile
@tapyu
tapyu / .c_cpp_files.md
Last active May 31, 2025 04:20
C/C++-related files for development in Vscode

C/C++-related files for development in Vscode

  • VScode files (they go in .vscode/) [[1]] [[2]]:
    • lauch.json: debugging configurations.
    • taks.json: create task to build the C/C++ project.
    • c_cpp_properties.json: settings related to IntelliSense.
  • .clang-format: rules for how your code should be formatted, such as indentation, line length, spacing, and so on. It is based on a predefined style to base the formatting on (in my case, I use the [Google style][3]).
  • Simple Makefile for a basic build system template.
  • Instructions to analyze a C/C++ code performance.
@cmccandless
cmccandless / pipeline.py
Last active February 27, 2019 01:25
Pipeline Demo
class Job():
def __init__(self, *args, **kwargs):
pass
def __call__(self, data):
raise NotImplementedError()
class Square(Job):
def __call__(self, data):
return [d * d for d in data]
@ramn
ramn / PrimeGenerator.scala
Last active September 19, 2019 08:14
Prime generator in Scala
val primes: Stream[Int] = 2 #:: Stream.from(3).filter { n => !primes.takeWhile(_ <= math.sqrt(n)).exists(n % _ == 0) }
def isPrime(n: Int) = primes.dropWhile(_ < n).head == n