Skip to content

Instantly share code, notes, and snippets.

View Output path comparison
nix-env failed:
error: undefined variable 'pythonOlder'
at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-6/pkgs/development/python-modules/django-postgresql-netfields/default.nix:17:14:
16|
17| disabled = pythonOlder "3.7";
| ^
18|
@jhonoryza
jhonoryza / setup-linux-server-ubuntu-focal.md
Created Dec 2, 2022
Setup VPS Linux Server Ubuntu 20.04 LTS
View setup-linux-server-ubuntu-focal.md

operating system

Ubuntu 20.04 LTS

server preparation

  1. install acl
  2. install nginx
  3. install php
  4. install composer
  5. install mysql server
  6. install git
View unidate.controller.ts
import { Get, JsonController } from 'routing-controllers'
import { Service } from 'typedi'
import Unidata, { Assets } from 'unidata.js'
const unidata = new Unidata()
@JsonController()
@Service()
export class UnidateController {
// http://localhost:3000/api/unidate
@Get('/unidate')
View network_status_wrapper.dart
import 'package:connectivity_plus/connectivity_plus.dart';
import 'package:flutter/material.dart';
import 'package:ismile/widgets/network/network_connectivity.dart';
enum NetworkStatus { offline, online }
@immutable
class NetworkStatusWrapper extends StatefulWidget {
const NetworkStatusWrapper({
super.key,
@Jonas164
Jonas164 / day2.kt
Created Dec 2, 2022
AoC 2022 Day 2
View day2.kt
package day2
import java.io.File
fun main() {
val list = day1.readFileLineByLine("src/main/kotlin/day2/input.txt");
var totalScore = 0;
list.forEach{
val tokens = it.split(" ");
totalScore += getWinScore(tokens[0],tokens[1]);
@Evgenion47
Evgenion47 / -2-2-homework_-regression-ipynb.ipynb
Created Dec 2, 2022
Копия блокнота "Задание 2.2 Homework_ regression.ipynb"
View -2-2-homework_-regression-ipynb.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View listen1_aha_playlist.md

本歌单由Listen1创建, 歌曲数:76,歌单数:2,点击查看更多

@akirataguchi115
akirataguchi115 / kela.py
Created Dec 2, 2022
Näin haet KELAn kuntoutuspsykoterapiaan Liisa Pankolan ohjeilla
View kela.py
f = open("input", "r")
o = open("output", "w")
lines = f.readlines()
f.close()
list = []
for line in lines:
if "HELSINKI" in line and not "http" in line:
split = line.split("\t")
o.write(split[len(split) - 1])
@HugsLibRecordKeeper
HugsLibRecordKeeper / output_log.txt
Created Dec 2, 2022
Rimworld output log published using HugsLib
View output_log.txt
Log uploaded on Friday, December 2, 2022, 4:01:38 PM
Loaded mods:
Harmony(brrainz.harmony)[mv:1.5.0.0]: 0Harmony(2.2.2), HarmonyMod(1.5.0)
Core(Ludeon.RimWorld): (no assemblies)
Ideology(Ludeon.RimWorld.Ideology): (no assemblies)
Vanilla Expanded Framework(OskarPotocki.VanillaFactionsExpanded.Core): 0MultiplayerAPI(av:0.3.0,fv:0.3.0), CompOversizedWeapon(1.0.0), ExplosiveTrailsEffect(1.0.7140.31563), GraphicCustomization(1.0.0), HeavyWeapons(1.0.0), KCSG(av:1.1.2,fv:22.9.11), MVCF(1.0.0), NoCamShakeExplosions(1.0.0), OPToxic(1.0.0), Outposts(av:3.0.0,fv:1.0.0), PipeSystem(av:1.0.1,fv:22.7.29), RecipeInheritance(1.0.0), Reloading(1.1.0), RRO(1.0.0), SmokingGun(1.0.0), VanillaStorytellersExpanded(1.0.0), VanillaWeaponsExpandedLaser(1.0.0), VFECore(av:1.1.7,fv:1.1.9), VWEMakeshift(1.0.0)
Vanilla Furniture Expanded - Security(VanillaExpanded.VFESecurity)[mv:1.1.1.0]: VFESecurity(1.1.2.2)
[KV] RimFridge(rimfridge.kv.rw)[ov:1.3.1.3]: RimFridge(1.2.1)
LWM's Deep Storage(LWM.DeepStorage)[mv:1.4.0.9]: IHoldMultipleThi
@dartharva
dartharva / adventofcode2022_day1.py
Created Dec 2, 2022
Advent of Code 2022, Day 1 - Simple, verbose python
View adventofcode2022_day1.py
with open('input.txt', 'r') as file:
calories = file.read().split('\n\n')
sums = [sum(int(x) for x in line.split()) for line in calories]
print(max(sums)) #Problem 1
top_3 = sorted(sums, reverse = True)[:3]
print(top_3, sum(top_3)) #Problem 2