Skip to content

Instantly share code, notes, and snippets.

@VictorTaelin
VictorTaelin / gpt4_abbreviations.md
Last active April 26, 2024 17:31
Notes on the GPT-4 abbreviations tweet

Notes on this tweet.

  • The screenshots were taken on different sessions.

  • The entire sessions are included on the screenshots.

  • I lost the original prompts, so I had to reconstruct them, and still managed to reproduce.

  • The "compressed" version is actually longer! Emojis and abbreviations use more tokens than common words.

import java.util.Scanner;
//Object : 이항 계수 1
//question : 자연수n 과 정수 k가 주어졌을 때 이항 계수nCk 를 구하는 프로그램을 작성하시오.
//Email : 99leehs@naver.com
public class Main11050 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int k = sc.nextInt();
System.out.println(C(n)/(C(k)*C(n-k)));
@pocesar
pocesar / nuke.js
Last active October 22, 2021 11:19
Facebook Javascript delete all photos
(async function walk() {
const waiter = (time) => (new Promise((resolve, reject) => {
setTimeout(resolve, time)
}))
const photo = document.querySelector('._3-8h._50zy._50-0._50z_._5upp._42ft')
const okBtn = '.uiOverlayFooter ._4jy0._4jy3._4jy1._51sy.selected._42ft'
if (photo) {
photo.click()
@tangzheng1900
tangzheng1900 / git_toturial
Created August 9, 2018 06:17 — forked from guweigang/git_toturial
git命令大全
git init # 初始化本地git仓库(创建新仓库)
git config --global user.name "xxx" # 配置用户名
git config --global user.email "xxx@xxx.com" # 配置邮件
git config --global color.ui true # git status等命令自动着色
git config --global color.status auto
git config --global color.diff auto
git config --global color.branch auto
git config --global color.interactive auto
git config --global --unset http.proxy # remove proxy configuration on git
git clone git+ssh://git@192.168.53.168/VT.git # clone远程仓库
@fpcMotif
fpcMotif / Useful wesites.md
Last active August 9, 2018 14:40
Useful wesites, learning resource for quant, machine/statistical learning and visualization. Some to be subscripted using rss
@ElToro1966
ElToro1966 / r_ubuntu_18_04.sh
Last active October 1, 2023 18:29 — forked from pachadotdev/r_ubuntu_17_10.sh
Install R and RStudio on Ubuntu 18.04 with essential libraries for data science. Based on pachamaltese/r_ubuntu_17_10.sh (for Ubuntu 17.10). Note: You need to make sure the default library location - /usr/local/lib/R/site-packages - is writable .
# Install R
sudo apt update
sudo apt install gdebi libxml2-dev libssl-dev libcurl4-openssl-dev libopenblas-dev r-base r-base-dev
# Install RStudio
cd ~/Downloads
wget https://download1.rstudio.org/desktop/bionic/amd64/rstudio-1.2.5001-amd64.deb
sudo gdebi rstudio-1.2.5001-amd64.deb
printf '\nexport QT_STYLE_OVERRIDE=gtk\n' | sudo tee -a ~/.profile
@jcheng5
jcheng5 / renderui_example.R
Created April 16, 2018 18:34
freezeReactiveValue examples
library(shiny)
library(ggplot2)
ui <- fluidPage(
sidebarLayout(
sidebarPanel(
selectInput("dataset", "Dataset", c("cars", "pressure", "mtcars")),
uiOutput("input_ui")
),
mainPanel(
@jcheng5
jcheng5 / dedupe.R
Created February 28, 2018 00:44
Lazy higher order reactives
library(shiny)
library(dplyr)
library(ggplot2)
dedupe <- function(r) {
x <- reactiveVal(isolate(r()))
o <- observe({
x(r())
})
@simecek
simecek / Map+Your+Twitter+Followers.ipynb
Last active August 7, 2021 05:35
Map your Twitter followers
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jcheng5
jcheng5 / shinymod.snippet
Last active January 22, 2019 14:09
RStudio snippet for Shiny module
snippet shinymod
${1:name}UI <- function(id) {
ns <- NS(id)
tagList(
${0}
)
}
${1:name} <- function(input, output, session) {