Skip to content

Instantly share code, notes, and snippets.

Avatar
👺
>>= (🙂 -> 👹)

Junsuk Park morishjs

👺
>>= (🙂 -> 👹)
View GitHub Profile
@morishjs
morishjs / alacritty.yml
Last active Jul 27, 2020
alacritty.yml for macOS
View alacritty.yml
# Configuration for Alacritty, the GPU enhanced terminal emulator
# Any items in the `env` entry below will be added as
# environment variables. Some entries may override variables
# set by alacritty it self.
env:
# TERM env customization.
#
# If this property is not set, alacritty will set it to xterm-256color.
#
View docker_compose.yml
# dcupd --no-build
version: '2.1'
services:
enterprise-merger:
image: doscode/merger-build-env:1.1
ports:
- "50051:50051"
command: >
bash -c "mkdir -p workspace && cd workspace
&& git clone --depth=50 --branch=master https://github.com/gruut/enterprise-merger.git
View Transaction
*** (1) TRANSACTION:
TRANSACTION 10521520362, ACTIVE 0 sec fetching rows
mysql tables in use 3, locked 3
LOCK WAIT 90 lock struct(s), heap size 13864, 186 row lock(s)
MySQL thread id 2215232, OS thread handle 0x7f00b060cb00, query id 14161131472 192.168.2.13 crema Sorting result
UPDATE reviews
LEFT OUTER JOIN
(
SELECT
id,
@morishjs
morishjs / LinkedList.js
Created Sep 19, 2016
LinkedList (javascript version)
View LinkedList.js
'use strict'
class Node{
constructor(value, nextNode){
this.value= value | 0;
this.nextNode = nextNode | null;
}
addNode(value){
//tail까지 탐색
var temp = this;
View Permutation.js
//기본 조건 : 현재 위치가 마지막 문자이면 출력
//재귀 조건 : 현재 위치에서 선택하지 않은 문자를 선택하고 다음 위치에서 새로운 문자를 선택하도록 함.
var stringArr = ['A', 'B', 'C', 'D'];
var exist = [];
for(var i = 0; i < stringArr.length;i++){
exist.push(false);
}
//n : 현재위치
//arr : 현재 만들어진 문자열
View Basic_webcrawler.py
import urllib2
import re
from bs4 import BeautifulSoup
parseUrl = urllib2.urlopen('http://python-data.dr-chuck.net/comments_300262.html')
soup = BeautifulSoup(parseUrl,'html.parser')
#regular expression to extract integer value
View InputStream.java
//If you press the "Enter" button, then successive characters is followed (Carriage return(13), Line feed(10)
public class Java155_stream {
public static void main(String[] args) {
// TODO Auto-generated method stub
InputStream inputStream = System.in;
System.out.println("이름: ");
int data;
View StreamExercise.java
public class StreamExercise {
public static void main(String[] args) {
// TODO Auto-generated method stub
String[] strings = {"d2", "a2", "b1", "b3", "c"};
Arrays.asList(strings).stream().filter(x->{
return x.startsWith("a");
}
).forEach(x-> System.out.println(x));
@morishjs
morishjs / asList.java
Last active Jul 25, 2016
Concatenate the array of strings.
View asList.java
String[] arrTest = { "1", "2", "3"};
List alTest = new ArrayList(Arrays.asList(arrTest));
String[] arrTest2 = { "4", "5", "6"};
Collections.addAll(alTest, arrTest2);
@morishjs
morishjs / IntStream.java
Created Jul 20, 2016
using concat feature.
View IntStream.java
package java0720_api;
import java.util.Arrays;
import java.util.stream.IntStream;
/**
* Created by Junsuk on 2016-07-20.
*/
public class Java142_System {
You can’t perform that action at this time.