language
stringclasses
15 values
src_encoding
stringclasses
34 values
length_bytes
int64
6
7.85M
score
float64
1.5
5.69
int_score
int64
2
5
detected_licenses
listlengths
0
160
license_type
stringclasses
2 values
text
stringlengths
9
7.85M
Java
UTF-8
4,471
3.078125
3
[]
no_license
package marvelydc.ui; import java.awt.BorderLayout; import java.awt.Color; import java.awt.Font; import java.awt.Graphics; import javax.swing.BorderFactory; import javax.swing.ImageIcon; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.border.Border; import marvelydc.mapeado.GenAleatorios; imp...
Python
UTF-8
2,577
3.09375
3
[]
no_license
import gym import numpy as np import matplotlib.pyplot as plt def convertObservation(observation): curRow = int(observation/4) curCol = observation%4 return (curRow,curCol) def determineAction(observation, state): """ Returns 0 (go left) or 1 (go right) depending on whether the weighte...
Python
UTF-8
1,312
2.640625
3
[]
no_license
import numpy as np from scipy import stats from specsens import util def pfa(noise_power, thr, n, dB=True): if dB: noise_power = util.dB_to_factor_power(noise_power) return 1. - stats.chi2.cdf(2. * thr / noise_power, 2. * n) def pd(noise_power, signal_power, thr, n, dB=True, num_bands=1): if dB...
Ruby
UTF-8
632
2.828125
3
[]
no_license
class ServiceResponse def initialize(success: false, message: nil, payload: nil) @success = success @message = message @wrapped_object = payload end def success? @success end def message @message end def unwrap @wrapped_object end def self.success ServiceResponse.new(s...
SQL
UTF-8
511
2.734375
3
[]
no_license
/*------------------------------------------------------------ * Script SQLSERVER ------------------------------------------------------------*/ /*------------------------------------------------------------ -- Table: stock ------------------------------------------------------------*/ CREATE TABLE stock( i...
Markdown
UTF-8
3,826
2.578125
3
[]
no_license
### 彭斯:川普对炸弹邮包事件没有责任 ------------------------ <p> 【大纪元2018年10月27日讯】(大纪元记者洪梅编译报导)美国中期选举将至的关键时期,针对连日来在美国政界掀起巨大波澜的炸弹邮包事件,美国副总统 <a href="http://www.epochtimes.com/gb/tag/%E5%BD%AD%E6%96%AF.html"> 彭斯 </a> (Mike Pence)周五(10月26日)说,总统 <a href="http://www.epochtimes.com/gb/tag/%E5%B7%9D%E6%99%AE.html"> 川普 </a> 对此没有任...
Java
UTF-8
1,903
2.265625
2
[]
no_license
package com.github.skp81.tkigui; import com.github.skp81.tkigui.listener.BlockClickHandler; import com.github.skp81.tkigui.listener.CommandHandler; import com.github.skp81.tkigui.listener.InventoryEventHandler; import com.github.skp81.tkigui.listener.ItemBreakHandler; import com.github.skp81.tkigui.manager.DataManager...
C++
UTF-8
1,446
3.453125
3
[]
no_license
// 290. Word Pattern (https://leetcode.com/problems/word-pattern/) // Author: Hritik Gupta class Solution { public: vector<string> split(string str){ vector<string> words; string curr = ""; for(int i=0; i<str.size(); i++){ if(str[i] == ' '){ words.p...
Java
UTF-8
11,750
2.15625
2
[]
no_license
package com.jacky8399.portablebeacons.events; import com.jacky8399.portablebeacons.BeaconEffects; import com.jacky8399.portablebeacons.Config; import com.jacky8399.portablebeacons.PortableBeacons; import com.jacky8399.portablebeacons.recipes.BeaconRecipe; import com.jacky8399.portablebeacons.recipes.RecipeManager; imp...
Java
UTF-8
987
2.515625
3
[]
no_license
package edu.uned.missi.tfm.appiumlib.conditional.impl; import java.util.HashMap; import edu.uned.missi.tfm.appiumlib.statement.Conditional; import io.appium.java_client.MobileElement; /** * Allows to evaluate if a RadioButton/CheckBox was selected * @author Paul Pasquel * */ public class Checked exte...
Python
UTF-8
1,145
3.625
4
[]
no_license
'''check out https://leetcode.com/problems/zigzag-conversion/description/''' class Solution(object): def convert(self, s, numRows): """ :type s: str :type numRows: int :rtype: str """ self.numRows = numRows allRows = [''] * numRows down = True ...
TypeScript
UTF-8
163
2.5625
3
[]
no_license
var printColors = function(...colors: string[]) { console.log(colors); } printColors("red"); printColors("red","blue"); printColors("red","green", "purple");
Shell
UTF-8
176
2.953125
3
[]
no_license
#!/usr/bin/env zsh # app related config APP="${BASH_IT}/app/*.zsh" for _bash_it_config_file in $~APP; do # shellcheck disable=SC1090 source "$_bash_it_config_file"; done
Python
UTF-8
210
3.328125
3
[]
no_license
import numpy as np t = np.array([0.,1.,2.,3.,4.,5.,6.]) print(t) print(t.ndim) print(t.shape) print(t[0],t[1],t[2]) print(t[2:5], t[-1]) # 2 : 2열 앞까지 , 3: 3열 부터 끝까지 print(t[:2], t[3:])
Python
UTF-8
441
3.15625
3
[]
no_license
import numpy as np # print(num_list.shape) def counter(num): num_list = np.zeros(num*100) for i in range(1,100): num_list[(i+1)*num-1]=1 for i in range(num-1): for j in range(1,100): num_list[(i+1)*(j+1)-1] = 0 count = 0 for i in num_list: if i:count+=1 ret...
Java
UTF-8
365
3.203125
3
[]
no_license
package src.chapter4; public class Exercise24 { public static void main(String[] args) { Integer i = new Integer(3); System.out.println(i); System.out.println(whichType(i)); } public static String whichType(Integer i) { return "Integer"; } public static String whi...
Python
UTF-8
4,737
3.03125
3
[]
no_license
#MACHINE LEARNING ALGORITHM(Linear Regression) import pandas as pd import numpy as np import matplotlib.pyplot as plt import statsmodels.formula.api as sm from sklearn.model_selection import train_test_split from sklearn import metrics House_Data=pd.read_csv("House_Data.csv",parse_dates=["date"]) Hous...
C#
UTF-8
844
3.421875
3
[ "MIT" ]
permissive
#region Usings using System; using System.Linq; using JetBrains.Annotations; #endregion namespace Extend { public static partial class StringEx { /// <summary> /// Extracts all letters of the input string. /// </summary> /// <exception cref="ArgumentNullException">The str...
Shell
UTF-8
647
2.578125
3
[]
no_license
# Maintainer: Simone Baratta -- Conte91 <at> gmail <dot> com pkgname=eigen-cmake-git pkgver=r2.d334930 pkgrel=1 pkgdesc="Eigen configuration files for CMake" arch=('any') license=('custom:"Beerware"') _reponame='eigen-cmake' url="http://github.com/Conte91/$_reponame" source=("git+https://github.com/Conte91/$_reponame.g...
Markdown
UTF-8
674
2.65625
3
[]
no_license
# benfeitoria/notification-php-sdk Este SDK deve ser utilizado para se comunicar com o [benfeitoria/notification](https://github.com/benfeitoria/notification). ## Instalação Para registrar o SDK como dependência utilize o comando: ``` compoer require benfeitoria/notification-php-sdk ``` ## Utilização Registre o *...
Python
UTF-8
1,351
3.078125
3
[]
no_license
#!/usr/bin/env python # -*- coding: utf-8 -*- ' a test module ' __author__ = 'FrancisD' import time class Funnel(object): def __init__(self, capacity, leaking_rate): self.capacity = capacity # max space self.leaking_rate = leaking_rate # quota/s self.left_quota = capacity # left space...
JavaScript
UTF-8
838
2.59375
3
[]
no_license
//Add //When the user click add player dispatch the action using player id const API_BASE_URL = 'http://localhost:8080'; export const addPlayer = (playerId) => dispatch => { // dispatch(authRequest()); //loading return ( fetch(`${API_BASE_URL}/team`, { method: 'PATCH',//post or patch ...
Shell
UTF-8
129
2.578125
3
[]
no_license
#!/usr/bin/env bash whom_variable="word" printf "HEllo, %s\n" "$whom_variable" printf "this is my arg %s %s %s\n" "$1" "$2" "$3"
Java
UTF-8
7,904
2.015625
2
[]
no_license
package org.nuxeo.nike; import java.sql.Connection; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.nuxeo.ecm.core.api.CoreSession; import org.nuxeo.runtime.datasource.ConnectionHelper; ...
Java
UTF-8
4,105
3.015625
3
[]
no_license
package training.chessington.model.pieces; import training.chessington.model.Board; import training.chessington.model.Coordinates; import training.chessington.model.Move; import training.chessington.model.PlayerColour; import java.util.ArrayList; import java.util.HashMap; import java.util.List; public cla...
Java
GB18030
941
2.453125
2
[]
no_license
package cn.kgc.dao.impl; import cn.kgc.dao.intf.PrescriptionMedicineDao; import cn.kgc.model.PrescriptionMedicine; public class PrescriptionMedicineDaoImpl extends BaseDaoImpl implements PrescriptionMedicineDao { public PrescriptionMedicineDaoImpl() { super("PrescriptionMedicineDao"); } /** * ѯҩƷϵݿСδʹõidţַĸ...
C++
UTF-8
2,654
2.546875
3
[]
no_license
#pragma once #ifndef scribble_master_h__ #define scribble_master_h__ #include <assert.h> #include <vector> #include <memory> #include <opencv2/opencv.hpp> #include "predefined_mask_manager.h" #include "scribble_types.h" #include "autofill_scribble.h" class ScribbleMaster { public: ScribbleMaster(): isReady_(fal...
TypeScript
UTF-8
1,830
2.984375
3
[]
no_license
import {Injectable} from '@angular/core'; import {Member, TalkState} from './Member'; @Injectable({ providedIn: 'root' }) export class MemberShufflerService { constructor() { } initializeMembers(): Member[] { // todo later make the names and count variable return [ {name: 'Jo', talkState: TalkS...
Python
UTF-8
1,189
3.453125
3
[]
no_license
#Q- To explore supervised Machine learning #importing libraries import numpy as np import matplotlib.pyplot as plt import pandas as pd #importing dataset dataset = pd.read_csv('http://bit.ly/w-data') X = dataset.iloc[:,:-1].values Y= dataset.iloc[:,1].values #Y is dependant vector. #splitting into trai...
C++
UTF-8
1,125
2.828125
3
[]
no_license
#include "pch.h" #include "CppUnitTest.h" #include "D:\vs项目文件\最大子段和\最大子段和\最大子段和.cpp" using namespace Microsoft::VisualStudio::CppUnitTestFramework; extern void Return_Max(int& Max, int* arr, int count); namespace UnitTest1 { TEST_CLASS(UnitTest1) { public: TEST_METHOD(TestMethod1) { int tru...
Shell
UTF-8
2,534
3.171875
3
[]
no_license
#!/bin/bash # Installation des paquets necessaires sur le serveur de deploiement # Parametrage de Cobbler # Deploiement des conf Ansible de base HYPERVISEUR_USER="pse32" # supprime flag rm -f prerequis.flag 2>/dev/null # Cree et deploie la cle SSH sur l'hyperviseur # si elle n'existe pas deja if [[ ! -e ${HOME}/.ss...
JavaScript
UTF-8
3,477
2.90625
3
[]
no_license
function Auto (marca, año, tipo, nombre, apellido, mail){ this.marca = marca; this.año = año; this.tipo = tipo; this.nombre = nombre; this.apellido = apellido; this.mail = mail; } function getPrecioPorMarca(marca){ if(marca === 'europeo'){ return 5000; } if(marca === 'americano...
Python
UTF-8
1,781
3.015625
3
[]
no_license
import tfidf import os def cleansourcecode( document ): """Replace all Non Alpha Numeric and Non space chars with a space""" # Also setting words to lower here... is this bad? return ''.join( e.lower() if e.isalnum() or e.isspace() else ' ' for e in document ) path = '/home/fox/hg/pyrapad/pyrapad/lib/gist...
Java
UTF-8
1,246
2.46875
2
[]
no_license
package com.vdab.rdcar.domain; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; import lombok.experimental.SuperBuilder; import org.springframework.format.annotation.DateTimeFormat; import javax.persistence.*; import java.io.Serializable; import java.time.LocalDate; import java.t...
Rust
UTF-8
249
3.1875
3
[]
no_license
#[derive(Debug)] struct X { a: i32 } impl Copy for X { } impl Clone for X { fn clone(&self) -> Self { *self } } fn main() { let x = X { a: 3 }; let y = x; println!("x and y value: {:?} {:?}", x, y); }
C++
UTF-8
11,300
3.1875
3
[]
no_license
#include <cmath> #include <utility> #include <cstdio> // #include "debug.h" #include "../common/cycleTimer.h" #define debug 0 void print_matrix(double **M, int r, int c) { /* for (int i = 0; i < r; i++) { for (int j = 0; j < c; j++) { printf("%lf ", M[i][j]); } printf("\n"); } */ } void print_vector(doub...
PHP
UTF-8
1,025
2.828125
3
[]
no_license
<?php namespace App\Auth; use Illuminate\Auth\EloquentUserProvider; use Illuminate\Contracts\Auth\UserProvider as UserProviderContract; class EmailOrNicknameUserProvider extends EloquentUserProvider implements UserProviderContract { /** * Retrieve a user by the given credentials. * * @param array...
Java
UTF-8
1,692
2.75
3
[]
no_license
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package Database; import businesslogic.User; import java.sql.Connection; import java.sql.ResultSet; import java.sql.SQLException; impo...
Java
UTF-8
1,018
2.34375
2
[]
no_license
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package com.gpms.pojo; /** * * @author Developer */ public class EventModel { private int eventid; private String eventdesc...
JavaScript
UTF-8
1,916
2.828125
3
[]
no_license
document.addEventListener("DOMContentLoaded", event => { const app=firebase.app(); console.log(app); const db=firebase.firestore(); const postsList=document.querySelector('#posts-list'); const postForm=document.querySelector("#makePostsForm"); function renderPost(doc) { let l...
Rust
UTF-8
2,728
3.078125
3
[]
no_license
#!/usr/bin/env rust-script //! ```cargo //! [package] //! edition = "2021" //! //! [dependencies] //! pathfinding = "4.2" //! ``` use std::{collections::HashSet, hash::Hash}; use pathfinding::prelude::astar; fn parse_input(input: &str) -> i32 { input.trim().parse().unwrap() } fn is_wall(seed: i...
C++
UTF-8
1,167
2.953125
3
[ "BSL-1.0" ]
permissive
#pragma once class RobotConfiguration { private: float speed; float health; float robotRotation; float turretRotation; int minFireCountdown; bool canNotShootAndMove; public: RobotConfiguration(): RobotConfiguration(0, 0, 0, 0, 0, true) {} RobotC...
Java
UTF-8
260
2.9375
3
[]
no_license
package ru.progwards.java1.lessons.bigints; public class IntInteger extends AbsInteger { String base; public IntInteger(int value){ base = Integer.toString(value); } @Override public String toString(){ return base; } }
Markdown
UTF-8
304
2.78125
3
[ "MIT" ]
permissive
# Calculator This is calculator with simple interface and supporting only basic math operations, written on JavaScript. The main idea here is the backend logic. It is entirely my concept and it works well. Adding new type of operations is easy, but this is not a goal for me. <br> <img src="a.png">
C#
UTF-8
3,941
2.625
3
[]
no_license
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace TB_QuestGame { /// <summary> /// static class to hold key/value pairs for menu options /// </summary> public static class ActionMenu { public enum CurrentMenu ...
C#
UTF-8
723
2.890625
3
[]
no_license
using System; using System.Collections.Generic; using System.Diagnostics; namespace SonosWp8 { public class ServiceFactory { private static readonly IDictionary<Type, Func<object>> Registrations = new Dictionary<Type, Func<object>>(); public static void Register<T, TR>(Func<TR> creator) where...
TypeScript
UTF-8
1,322
2.53125
3
[]
no_license
import { sign } from 'jsonwebtoken' import { IResponseUserModel } from '@modules/users/infra/schemas/user' import AppError from '@shared/errors/app-error' import IUserRepository from '@modules/users/infra/repositories/protocols/i-user-repository' import IBcryptAdapter from '@shared/infra/adapters/protocols/i-bcrypt-ada...
Java
UTF-8
697
1.953125
2
[]
no_license
package com.turbid.basicapi.entity.shop.commodity; import com.turbid.basicapi.tools.CodeLib; import lombok.Data; /** * 商品类 */ @Data public class Commodity { private static final String TABLE_CODE= "commodity"; //商品编号 private String code; public String getCode() { if (null==code) { ...
Python
UTF-8
430
3.046875
3
[]
no_license
#!/usr/bin/env python #coding=utf-8 from __future__ import print_function import random def apple(): print("您選擇了蘋果") def orange(): print("您選擇了橘子") def banana(): print("您選擇了香蕉") def default(): print("沒有您選擇的") case = "apple" switch = { 'apple' : apple, 'orange' : orange, 'banana' : banana, } ...
C#
UTF-8
592
2.515625
3
[ "MIT" ]
permissive
using System; using System.Collections.Generic; using System.Text; namespace FriendlyRAT.Core.Windows { using System.ComponentModel; using System.Drawing; internal static class CursorManager { public static Point GetCursor() { if (Native.GetCursorPos(out var pos)) ...
Markdown
UTF-8
8,099
3.015625
3
[ "BSD-3-Clause" ]
permissive
<a id="tags_8c"></a> # File tags.c ![][C++] **Location**: `examples/tags.c` Advanced example of PicoTest test filter, implements a primitive tagging feature for test filtering. ```cpp #include <stdio.h> #include <picotest.h> /* Custom test filter function declaration. */ PicoTestFilterProc matchTag; #undef PICOTE...
Java
UTF-8
854
3.296875
3
[]
no_license
/** * Definition for singly-linked list. * public class ListNode { * int val; * ListNode next; * ListNode(int x) { val = x; } * } */ class Solution { public ListNode addTwoNumbers(ListNode l1, ListNode l2) { int carry = 0; int sum = 0; ListNode dummyHead = new Lis...
C++
GB18030
576
3.625
4
[]
no_license
//עָ÷while÷ֱҵΪֹ //չҲɰǷΪżж϶չΪκ void ReorderOddEven(int *pData, unsigned int length) { if(pData == NULL || length <= 0) return; int *pBegin = pData; int *pEnd = pData + length - 1; while(pBegin < pEnd) { while(pBegin < pEnd && (*pBegin & 0x1) != 0) pBegin++; while(pBegin < pEnd && (*pEnd & 0x1) == 0) pE...
Markdown
UTF-8
357
2.609375
3
[ "MIT" ]
permissive
# One Page Portfolio Site A single web page portfolio site. Created as part of Udacity's FEND nanodegree. Completely responsive. Flexbox based layout. Live version via custom domain: [www.sunnymui.com](http://www.sunnymui.com) Original GitHub Pages link: [https://sunnymui.github.io/one-page-portfolio/](https://sun...
Python
UTF-8
663
3.359375
3
[]
no_license
def choose_one(so_far, nums, squares): #print(so_far, nums) if not nums: return so_far else: for n in nums: if not so_far or so_far[-1] + n in squares: n2 = nums[::] n2.remove(n) ans = choose_one(so_far + [n], n2, squares) ...
C#
UTF-8
4,441
2.703125
3
[]
no_license
using System; using System.Collections.Generic; using System.Linq; using System.Text; using Xamarin.Forms; using System.Collections.ObjectModel; using Newtonsoft.Json; using System.Net.Http; using ItemType; using favType; namespace Viasat_App { public partial class ResultsPage : ContentPage { public ...
Python
UTF-8
4,148
3.328125
3
[]
no_license
# https://raw.githubusercontent.com/wessilfie/BasicBGMBot/master/app.py import random from flask import Flask, request from pymessenger.bot import Bot import os from web_scraper import get_restaurant_menu, get_restaurant_entree RESTAURANT_ORDER = {"CAFE_3": 0, "CLARK_KERR_CAMPUS": 1, ...
PHP
UTF-8
862
2.625
3
[]
no_license
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>Hello World</title> <link rel="stylesheet" href=""> </head> <body> <?php $conn = mysqli_connect('localhost','root',''); if (!$conn) { die ('ket noi that bai'. mysqli_connect_error()); } mys...
Python
UTF-8
793
2.765625
3
[]
no_license
#!/usr/bin/env python3 import requests import getpass class Login: def __init__(self,user='',password=''): self.session=requests.session() self.login=dict() self.url='https://www.newbiecontest.org/forums/index.php?action=login2' self.connection(user,password) def connection(self,user='',password=''): if ...
PHP
UTF-8
1,721
3.09375
3
[ "MIT" ]
permissive
<?php namespace Wookieb\ZorroDataSchema\SchemaOutline\TypeOutline; /** * @author Łukasz Kużyński "wookieb" <lukasz.kuzynski@gmail.com> */ class ClassOutline extends AbstractTypeOutline { /** * @var ClassOutline */ private $parentClass; private $properties = array(); public function __cons...
Markdown
UTF-8
1,025
3.21875
3
[]
no_license
<html> <h1>Project: JavaScript Web Scrapping</h1> <p><strong>In this project we will understand how to manipulate JSON data, how to use the request module and how to fetch URLs, for last how to read and write a file using the fs module.</strong></p> <body> <li>Task 0: Write a script that reads and prints the content of...
PHP
UTF-8
236
2.625
3
[]
no_license
<?php namespace Core; class DependencyContainer { private static $instances = array(); public function __construct() { } public function getCar() { } public function getMotocycle() { } }
Java
UTF-8
264
2.203125
2
[]
no_license
package businesslogic; import auxilary.models.User; /** * Created by Anastacia on 21.03.2018. */ public interface AccountManagerInterface { public boolean signUp(User user); public boolean login(User user); public User getCurrentAccountUser(); }
C#
UTF-8
490
2.546875
3
[ "MIT" ]
permissive
using Pharmacy.BusinessLayer.Models; namespace Pharmacy.PresentationLayer.Models { public class UserViewModel { public UserViewModel(int id, string username, string pharmacyName) { Id = id; Username = username; PharmacyName = pharmacyName; } public UserViewModel(User user) : thi...
Markdown
UTF-8
4,381
2.78125
3
[]
no_license
## 郭文贵2021年3月11日盖特 20210311_1尊敬的战友们好!GTV可能被骇客的紧急通知! [轉載自GNews](https://gnews.org/ThreadView/53480350) 3月11号,尊敬的战友们好啊! 首先我今天,先给大家聊聊就是咱们这个G-TV的紧急事件。从昨天晚上,(G-TV)遭受了大量共匪的所谓的网络黑客攻击。最重要的事情是刚刚的几个小时前,就所有G-TV的直播有两个功能。咱们这个直播当中啊,用的是声网(平台)直播的。大概再过一两个月,咱们就可以不用声网了,就(可以)完全独立了。现在用的是声网这个平台,主要是两个功能,一个就是直播功能,一个就是信息通知功能。 昨天晚上...
Java
UTF-8
937
3.296875
3
[]
no_license
package com.technical.google; public class MatrixFind { /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub int[][] matrix = {{1}}; boolean x = searchMatrix(matrix,-1); if(x==true) { System.out.println("True"); } else { System.out.println("False...
Java
UTF-8
2,177
2.078125
2
[ "BSD-3-Clause" ]
permissive
package com.ociweb.behaviors.inprogress; import com.ociweb.gl.api.PubSubFixedTopicService; import com.ociweb.gl.api.PubSubMethodListener; import com.ociweb.gl.api.StartupListener; import com.ociweb.iot.grove.oled.oled2.OLED96x96Transducer; import com.ociweb.iot.maker.FogCommandChannel; import com.ociweb.iot.maker.FogR...
Markdown
UTF-8
6,391
3.25
3
[]
no_license
# 0217 ## NextJS - 리액트에서 SSR을 위한 도구 가장 큰 이유 : SSR을 위해서! Vue에는 NuxtJS가 있다. 그리고 Angular에는 Angular Universal 이번 자란다 2.0을 위해서 유니버셜을 공부해놔야한다. --- GraphQL : SQL처럼 data query language이다. 요청받은 구조로 데이터를 반환하는 특징이 있다. 다음과 같은 데이터가 있다면, ``` Users = [ { firstName '준우', lastName: '박' }, { firstName '여울', ...
Java
UTF-8
750
2.75
3
[]
no_license
package com.books.notebasecore.util; import java.util.List; public class ArrayUtil { /** * 是否存在下标 * * @param arr * @param index * @return */ public static boolean isArrayIndex(String[] arr, int index) { try { String str = arr[index]; } ...
Java
UTF-8
794
3.390625
3
[]
no_license
@SuppressWarnings("all") public class JDKAnnotation { /* * JDK中预定义的一些注解 * @Override :检测被该注解标注的方法是否是继承自父类(接口)的 * @Deprecated:该注解标注的内容,表示已过时 * @SuppressWarnings:压制警告 * 一般传递参数all @SuppressWarnings("all") */ @Override //检测被该注解标注的方法是否是继承自父类(接口)的 public String toString() { ...
JavaScript
UTF-8
1,938
2.859375
3
[]
no_license
async function perform_fetch() { var requesturl = window.location.protocol + "//" + window.location.host + "/tickets/json"; response = await fetch(requesturl); response = await response.json(); return response; } async function search_tickets() { response = await perform_fetch(); var userE...
Java
UTF-8
5,416
1.976563
2
[]
no_license
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package com.fillingstationproject.entity; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fillingstationproject.util.Re...
Java
ISO-8859-1
3,984
3.328125
3
[]
no_license
package agenda; import java.util.ArrayList; import java.util.regex.Pattern; import java.util.Scanner; public class Agenda { ArrayList<Contacto> contactos; public Agenda() { this.contactos = new ArrayList<Contacto>(); } public boolean AddContacto(String nombre, String apellidos, String dni, String telefono) {...
Java
UTF-8
3,489
3.453125
3
[]
no_license
import java.util.Random; import java.util.List; public class FrenchKnight extends Player{ Random rand = new Random(); int cowHeal = 40; final String castle = "The French Knight somehow found a castle to reside in. "; boolean isCastle; Cow cow; public FrenchKnight (World w, String name, Location ...
Markdown
UTF-8
806
2.640625
3
[]
no_license
# Data Serialization ## What are data serialization formats? XML, JSON, BSON, YAML, MessagePack, Protocol Buffers, Thrift and Avro. ## Resource [Big Data File Formats Demystified by Alex Woodie](https://www.datanami.com/2018/05/16/big-data-file-formats-demystified/) | Avro, Parquet and ORC [Data Serialization – ...
TypeScript
UTF-8
7,060
3.765625
4
[]
no_license
// https://www.educative.io/courses/grokking-the-coding-interview/Y5zDWlVRz2p // // Needless to say that we need a maxHeap so that we can always greedily pop // out from the stack follow the given rule // The maxHeap should compare its elements in two ways: // 1. compare their frequencies // 2. if frequencies are th...
Markdown
UTF-8
3,628
3.09375
3
[]
no_license
--- title: "ICON Nodes" excerpt: "" --- This document presents what kinds of nodes are in the ICON network. Node means the computer server which participates in the blockchain protocol. All nodes keep the full or partial copy of blockchain data and execute transactions in the blocks for validation. So all nodes...
PHP
UTF-8
238
3.90625
4
[]
no_license
<?php //Create a script that displays 1-2-3-4-5-6-7-8-9-10 on one line. There will be no hyphen(-) at starting and ending position. for($x=1; $x<=10; $x++) { if($x< 10) { echo "$x-"; } else { echo "$x"."\n"; } } ?>
C#
UTF-8
1,715
2.59375
3
[]
no_license
using System.Collections; using System.Collections.Generic; using UnityEngine; public class Paddle { /// <summary> /// The speed the player can move his bar with (bar meaning the block on the right side) /// </summary> private float _speed; /// <summary> /// The x-axis postion where the player...
Python
UTF-8
323
3.21875
3
[]
no_license
# difflib.get_close_matches returns a list of the best “good enough” matches. # This script is to demonstrate that from difflib import get_close_matches names = ['julian', 'pythonista', 'sara'] print(get_close_matches('python', names)) print(get_close_matches('jul', names)) print(get_close_matches('ara', names))
Swift
UTF-8
1,829
3.140625
3
[]
no_license
// // Interest Calculator.swift // GroupProject // // Created by Angela Garrovillas on 9/16/19. // Copyright © 2019 Angela Garrovillas. All rights reserved. // import Foundation struct InterestCalculator { var goal: Double var interestRate: Double var numOfYears: Int var total: Double = 0 var m...
Java
UTF-8
9,815
1.875
2
[]
no_license
/** * <copyright> * </copyright> * * $Id$ */ package org.storydriven.storydiagrams.calls.util; import org.eclipse.emf.common.notify.Adapter; import org.eclipse.emf.common.notify.Notifier; import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; import org.eclipse.emf.ecore.EObject; import org.sto...
Markdown
UTF-8
6,245
2.859375
3
[]
no_license
谈画(1) 我从前的学校教室里挂着一张“蒙纳.丽萨”,意大利文艺复兴时代的名画。先生说:“注意那女人脸上的奇异的微笑。”的确是使人略感不安的美丽恍惚的笑,像是一刻也留它不住的,即使在我努力注意之际也滑了开去,使人无缘无故觉得失望。先生告诉我们,画师昼这张图的时候曾经费尽心机搜罗了全世界各种罕异可爱的东西放在这女人面前,引她现出这样的笑容。我不喜欢这解释。绿毛龟,木乃伊的脚,机器玩具,倒不见得使人笑这样的笑。使人笑这样的笑,很难罢?可也说不定很容易。一个女人蓦地想到恋人的任何一个小动作,使他显得异常稚气?可爱又可怜,她突然充满了宽容,无限制地生长到自身之外去,荫庇了他的过去与将来,眼睛里就许有这样的苍茫的微笑。 ...
Markdown
UTF-8
4,741
2.859375
3
[]
no_license
--- coverImage: /posts/taming-unity/cover.jpg date: '2014-04-26T00:42:52.000Z' tags: - games - mvc - robotlegs - strangeioc - unit testing title: Taming Unity oldUrl: /c/taming-unity --- [![logo](https://www.mikecann.co.uk/wp-content/uploads/2014/04/logo.png)](https://www.mikecann.co.uk/wp-content/uploads/20...
SQL
UTF-8
290
2.71875
3
[ "MIT" ]
permissive
create user :db_user with password ':db_password'; alter user :db_user createdb; alter user :db_user set client_encoding to 'utf8'; alter user :db_user set default_transaction_isolation to 'read committed'; alter user :db_user set timezone to 'UTC'; create database :db_name owner :db_user ;
C++
UTF-8
4,422
2.65625
3
[]
no_license
#include "ExecutorManager.h" namespace robot{ bool ExecutorManager::getWorldProperty() const{ return true; } bool ExecutorManager::setWorldProperty(){ return true; } bool ExecutorManager::sendMessage(Message* message){ messageQueueLock.lock(); messageQueue.push(message); messageQueueLock.unlock...
Java
UTF-8
456
1.609375
2
[]
no_license
/** * FileName: CourseCollectVo * Author: ljl * Date: 2021/7/15 11:50 * Description: * History: */ package com.ljl.guli.service.edu.entity.vo; import lombok.Data; import java.math.BigDecimal; @Data public class CourseCollectVo { private String courseId; private String courseTitle; private BigDec...
C
UTF-8
774
2.578125
3
[ "MIT" ]
permissive
/* Your program is supposed to create a full red screen in MSDOS. The source of the binary (.com file) must be 5 bytes or less. No wild assumptions, the binary must work in MsDos, DosBox, and FreeDos alike. For winning, you have to post x86 assembler code which can be assembled with NASM (FASM) or directly the hex cod...
C++
UTF-8
11,525
3.5
4
[]
no_license
#ifndef _MATHHELPER_H #define _MATHHELPER_H #include <cmath> // For voxels #define SUBDIV_X 0 #define SUBDIV_Y 1 #define SUBDIV_Z 2 #define VECTOR_INCOMING 0 #define VECTOR_OUTGOING 1 #define PI 3.14159265 /* * The Color class, RGB should be between 0 and 1 */ struct Color { // RGB double r, g, b; //...
Shell
UTF-8
295
2.53125
3
[]
no_license
#!/bin/bash set -ex DEV_IMAGE_NAME="jincort/frontend-supreme-happiness-develop" PROD_IMAGE_NAME="jincort/frontend-supreme-happiness" TAG="${1}" docker push ${DEV_IMAGE_NAME}:${TAG} docker build -f Dockerfile.prod --no-cache -t ${PROD_IMAGE_NAME}:${TAG} . docker push ${PROD_IMAGE_NAME}:${TAG}
SQL
UTF-8
1,434
4.25
4
[]
no_license
SELECT c.posting_date AS "Posting Date:Date:80", c.voucher_no AS "Voucher No:Text:150", c.debit AS "Amount Invoiced:Currency:120", c.credit AS "Payment Recieved:Currency:120", c.due AS "Amount Due:Currency:120", c.remarks as "Remarks:Text:360" FROM (SELECT posting_date, voucher_no, doc...
PHP
UTF-8
2,790
2.578125
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Models\Food; use App\Models\Meal; class FoodsController extends Controller { /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { // } /*...
Java
MacCyrillic
3,383
3.203125
3
[]
no_license
import java.io.DataInputStream; import java.io.InputStream; import java.util.ArrayList; class FastScanner { private DataInputStream din; final private int bufferSize; private int bytesCount; private byte[] buffer; private int bufferCur; public FastScanner(InputStream in) { din = new DataInputStream(in); b...
TypeScript
UTF-8
572
3.5
4
[]
no_license
function addition(num1: number, num2: number): number { const add: number = num1 + num2; return add; } function multiplication(num1: number, num2: number): number { const multi: number = num1 * num2; return multi; } function subtraction(num1: number, num2: number): number { const sub: number = num1 - num2; ...
C#
UTF-8
728
2.71875
3
[]
no_license
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace _piataAZ.Entities { public class Ad { private String _title; private String _description; private String _usernameEmployee; private String _image; public Ad(String title, St...
C
UTF-8
1,851
4.21875
4
[]
no_license
#include "util.h" #include <ctype.h> #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <sys/types.h> /** * Trim the given string by replacing the spaces with null character * @param char * str */ void str_trim(char * str) { uint8_t start_flag, end_flag; int len; start_flag = end_flag...
C++
UTF-8
1,074
3.40625
3
[]
no_license
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ class Solution { public: ListNode* partition(ListNode* head, int x) { if (head == NULL || head->next == NULL) return head; ListNo...
C#
UTF-8
1,283
2.515625
3
[]
no_license
using UnityEngine; using System.Collections; using UnityEngine.UI; using System; public class SearchButtonOnClick : MonoBehaviour { public Text start; public Text fin; public Text time; public Text amount; public void OnClick() { ErrorHandler.hide(); GameObject init = GameOb...
Java
UTF-8
1,580
2.375
2
[]
no_license
package com.qqhr.platfrom.handler; import com.qqhr.common.enums.TopicEnum; import com.qqhr.platfrom.executor.ExecutorPipeline; import com.qqhr.platfrom.interfaces.IHandler; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework...
C
UTF-8
1,367
3.546875
4
[]
no_license
// // main.c // 08_05_Challenge // // Created by jim Veneskey on 1/26/16. // Copyright © 2016 Jim Veneskey. All rights reserved. // #include <stdio.h> #include <stdlib.h> // Function prototype void buySellOrHold(int price); void finalDecision(char bsoh); int main(int argc, const char * argv[]) { // insert co...