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
C#
UTF-8
1,180
3.125
3
[]
no_license
using System; using System.Windows.Input; namespace VideoFeatureMatching.Utils { public class Command<T> : ICommand { private readonly Action<T> _action; private readonly Func<T, bool> _canExecute; public Command(Action<T> action) : this(action, parametr => true) {...
Markdown
UTF-8
1,880
2.796875
3
[]
no_license
She's just woken up. The dim lighting of her room soft to her eyes. Rolling over, she gathers the blankets around her and looks down at herself. Smiling as she compares herself to a string bean or pea pod, she shifts her thoughts over again. The words are hesitant to come. _Depressed_. It wasn't official by any means...
PHP
UTF-8
54
2.859375
3
[]
no_license
<?php fscanf(STDIN, "%d", $x); echo $x >= 0 ? $x : 0;
Markdown
UTF-8
2,764
2.875
3
[]
no_license
--- layout: post title: Fried chicken chops with cheese sauce date: 2019-04-15 22:30:00 +0800 categories: Chinese_snacks_DIY --- # Fried chicken chops with cheese sauce ![Fried chicken chops with cheese sauce]({{site.baseurl}}/img/430269/430269.jpg) # Introduction **"Cheese is extracted from milk. It i...
Java
UTF-8
176
1.8125
2
[]
no_license
package com.MO.MatterOverdrive.gui.events; /** * Created by Simeon on 5/5/2015. */ public interface IListHandler { void ListSelectionChange(String name,int selected); }
Java
UTF-8
10,399
2.0625
2
[]
no_license
/** */ package statemachine.impl; import org.eclipse.emf.ecore.EAttribute; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EPackage; import org.eclipse.emf.ecore.EReference; import org.eclipse.emf.ecore.impl.EPackageImpl; import statemachine.FinalState; import statemachine.InitialState; import sta...
Python
UTF-8
195
3.28125
3
[]
no_license
nama = 'Ahmad Rizky Febianto' nim = 212410102097 umur = '18 tahun' tinggi_badan = 172.5 berat_badan = 65 print(nama) print(nim) print(umur) print(tinggi_badan, 'cm') print(berat_badan, 'Kg')
C
UTF-8
1,665
3.484375
3
[]
no_license
/* ** EPITECH PROJECT, 2019 ** PSU_minishell1_2018 ** File description: ** minishell1 */ #include "include_linked_list/linked_list.h" void norme_function(list_t *list, elem_t *new_elem, int pos) { int i = 0; for (elem_t *elem = list->start; elem != NULL && i < pos; elem = elem->next, i++) { n...
Markdown
UTF-8
1,929
3.296875
3
[ "LicenseRef-scancode-free-unknown", "MIT" ]
permissive
--- sidebar_position: 2 sidebar_label: Panel --- # Module: Panel An extension can register a Panel Module by defining a `getPanelModule` method. The panel module provides the ability to define `menuOptions` and `components` that can be used by the consuming application. `components` are React Components that can be di...
C#
UTF-8
1,230
2.71875
3
[ "MIT" ]
permissive
using MJKProjectsDAL.Models.Base; using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using System.Text; using Microsoft.EntityFrameworkCore; namespace MJKProjectsDAL.Models { [Table("projects")] public class Project ...
C#
UTF-8
2,305
2.921875
3
[]
no_license
using TMPro; using UnityEngine; namespace Managers { public class ScoreManager : MonoBehaviour { private int _score, _lines, _level; private bool _didLevelUp; [SerializeField] private int linesPerLevel = 5; private const int MinLines = 1; private const int MaxLines =...
Markdown
UTF-8
1,094
3.25
3
[]
no_license
# SuperJDBC Turn your Java models into Super Models This is a lightweight Java library that lets you concentrate on your application's logic rather than database stuff. No more SQL in your code. Yes, there is Hibernate, ActiveJDBC, ActiveJPA and so on but this is much simpler to get started with and use. And, it is c...
Java
UTF-8
1,271
2.3125
2
[ "Apache-2.0" ]
permissive
package hu.unideb.inf.rft.neuban.service.annotations.validators; import hu.unideb.inf.rft.neuban.service.annotations.FieldMatch; import lombok.extern.slf4j.Slf4j; import org.apache.commons.beanutils.BeanUtils; import javax.validation.ConstraintValidator; import javax.validation.ConstraintValidatorContext; @Slf4j pub...
Python
UTF-8
262
3.609375
4
[]
no_license
# if문 print('누구십니까?') your_name = input() if your_name == '도깨비': print('안녕하세요. 도깨비님!') elif your_name == '저승사자': print('저승사자님, 또 야근이시군요!') else: print(your_name + '..., 뉘신지?')
Java
UTF-8
2,699
2.453125
2
[]
no_license
package com.example.dreizehn.mypopularmoviesproject.utility.AdapterPackage; import android.content.Context; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; impor...
JavaScript
UTF-8
3,777
2.84375
3
[]
no_license
import React, { useState } from "react"; const Form = () => { const [txtUsername, setTxtUsername] = useState(""); const [age, setAge] = useState(0); const [formErrors, setFormErrors] = useState({ textUsername: "", age: "" }); const [fieldValidity, setFieldValidity] = useState({ textUsername: false, ...
Java
UTF-8
819
2.625
3
[]
no_license
package com.jinxp09277.j.library.log; import android.util.Log; import androidx.annotation.NonNull; import static com.jinxp09277.j.library.log.JLogConfig.MAX_LEN; /** * Created by LWB on 2020/10/27 */ public class JConsolePrinter implements JLogPrinter{ @Override public void print(@NonNull JLogConfig confi...
Markdown
UTF-8
755
2.734375
3
[]
no_license
# BusyBus A public transportation application project designed to apply frontend skills to build bus route views. HTML and CSS were the primary coding languages used to complete this project but Figma was used to design the application. ## Colors * **Black** - Used as a nuetral color to be easy on the eyes when a user...
Java
UTF-8
333
2.515625
3
[]
no_license
public class AdapterPattern { //This is the client class. public static void main(String args[]){ Extension targetInterface=new parkingCustomer(); targetInterface.giveVehicleDetails(); System.out.print(targetInterface.getFeeDetails()); } }//End of the BankCus...
Java
UTF-8
934
2.5
2
[]
no_license
package controllers; import models.*; import java.util.List; /** * Write a description of class SwitchUserController here. * * @author (your name) * @version (a version number or a date) */ public class SwitchUserController extends Controller { /** * Constructor for objects of class SwitchUserControll...
Java
UTF-8
1,539
3.15625
3
[]
no_license
package com.yale.test.design.iterator; import java.util.Iterator; import com.yale.test.design.iterator.before.CafeMenu; import com.yale.test.design.iterator.before.DinerMenu; import com.yale.test.design.iterator.before.MenuItem; import com.yale.test.design.iterator.before.PancakeHouseMenu; public class Test { Men...
Shell
UTF-8
92
2.828125
3
[]
no_license
#!/bin/bash # id command (internal) case $1 in ("-u" | "-g") echo `id $1 $2` ;; esac
C#
UTF-8
1,539
2.578125
3
[ "MIT" ]
permissive
using System; using Zilon.Core.Schemes; namespace Zilon.Core.Persons { /// <summary> /// Текущее состояние перка персонажа. /// </summary> public class Perk : IPerk { public Perk(IPerkScheme scheme) { Scheme = scheme ?? throw new ArgumentNullException(nameof(scheme)); ...
Markdown
UTF-8
286,257
2.75
3
[]
no_license
--- layout: manual title: Integration Manual description: The purpose of this documentation is to guide the developer on how to integrate with Cielo's API Cielo eCommerce. search: true translated: true categories: manual tags: - API e-Commerce Cielo language_tabs: json: JSON shell: cURL --- # Overview - API Ciel...
Java
UTF-8
1,234
2.734375
3
[]
no_license
package com.leverx.learn.blogme.service; /** * @author Viktar on 06.06.2020 * * Provides methods for work with activation codes */ public interface ActivationCodeService { /** * Allows to activate an user {@link com.leverx.learn.blogme.entity.User} using activation code. * * @param code Code wh...
Java
UTF-8
5,447
2.9375
3
[]
no_license
package kata.supermarket; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; import java.math.BigDecimal; import java.util.Arrays; import java.util.Collections; import j...
TypeScript
UTF-8
640
2.84375
3
[]
no_license
class GameObject { public div: HTMLElement; public x: number = 0; public y: number = 0; public xspeed: number = 0; public yspeed: number = 0; public speedmultiplier: number = 1; public width: number; public height: number; public direction: number = 1; constructor(tag: string, ...
JavaScript
UTF-8
1,408
2.671875
3
[]
no_license
var COMMERCIAL = { imgArray:[], currIndex:0, path:'img/', numImages:0, interv:null, timeout:6000, active:true } COMMERCIAL.init = function(){ COMMERCIAL.imgArray = ["commercial/1.jpg", "commercial/2.jpg"]; COMMERCIAL.currIndex=0; COMMERCIAL.numImages=COMMERCIAL.imgArray.length; COM...
Python
UTF-8
1,507
2.875
3
[ "Apache-2.0" ]
permissive
import os.path __author__ = 'Sina Solaimanpour' responses = { 'MajorTests Tricky Words': 'http://www.vocabulary.com/lists/682592#view=notes', 'Official GRE Verbal': 'http://www.vocabulary.com/lists/700826#view=notes', 'Magoosh Tricky Words': 'http://www.vocabulary.com/lists/687078#view=notes' } def read...
JavaScript
UTF-8
5,346
2.859375
3
[]
no_license
test('Card.init', function() { var C = Card(); var card = new C.Card(C.CardKind.Club, C.CardNum.Ace); QUnit.equal(card.name(), 'club1', 'card Club Ace has name club1'); var card = new C.Card(C.CardKind.Special, C.CardNum.Joker); QUnit.equal(card.name(), 'special15', 'card Special Joker has na...
Java
UTF-8
910
2.828125
3
[]
no_license
/****************************************************************************** Online Java Compiler. Code, Compile, Run and Debug java program online. Write your code in this editor and press "Run" button to execute it. *****************************************************...
Java
UTF-8
1,354
1.75
2
[]
no_license
/** * <copyright> * </copyright> * * $Id$ */ package net.sf.ictalive.coordination.wfvv; import org.eclipse.emf.ecore.EFactory; /** * <!-- begin-user-doc --> * The <b>Factory</b> for the model. * It provides a create method for each non-abstract class of the model. * <!-- end-user-doc --> * @see net.sf.ictal...
Markdown
UTF-8
1,563
2.65625
3
[]
no_license
--- id: 324 title: Div centralizada vertical/horizontal, e fixa com rolagem da janela date: 2011-03-23T09:01:07+00:00 author: William Bruno layout: post guid: http://www.wbruno.com.br/blog/?p=324 permalink: /javascript-puro/div-centralizada-verticalhorizontal-fixa-rolagem-da-janela/ dsq_thread_id: - "2102136911" cate...
Markdown
UTF-8
1,847
3
3
[]
no_license
# GitPitch Enterprise Prerequisites GitPitch Enterprise is delivered as a [Docker container](https://docs.docker.com) running in a Linux server environment. At runtime the enterprise container depends on a [Docker volume](https://docs.docker.com/storage/volumes) at runtime. This volume is used: 1. To pass custom GitP...
Markdown
UTF-8
5,811
3.078125
3
[]
no_license
# webpack是什么? Webpack是一款模块打包工具,你可以用它来帮助你打包。但是随着社区的发展,很多开发插件的涌现,这种定义越发模糊起来。一些插件所做的功能任务已经远远超出了打包的范畴,举例来说,有些插件可以帮助我们清理打包目录,还有的插件可以帮助我们处理打包后文件的线上部署。 Webpack在React中非常的受青睐,因为它支持热模块替换(Hot Module Replacement),这也使得webpack迅速变的家喻户晓,甚至扩展到了其他语言的开发中,比如Ruby On Rails。看到webpack中的web这个单词,你可能觉得webpack只能应用于网页开发之中,可不是这样的!webpack可以打包其他的资源...
Shell
UTF-8
741
3.234375
3
[ "ISC" ]
permissive
#!/usr/bin/env bash source ./scripts/_init set -x # setup workspace o="$BASE_DIR" rm -rf "${o}" mkdir -p "${o}/node_modules" mkdir -p "${o}/bin" cp "$ROOT_DIR/README.md" "${o}" cp "$ROOT_DIR/LICENSE" "${o}" cp "$ROOT_DIR/package.json" "${o}" cp "$ROOT_DIR/yarn.lock" "${o}" cp -rv "$ROOT_DIR/lib" "${o}/lib" ( cd "...
Markdown
UTF-8
1,731
2.8125
3
[]
no_license
# 简介 本项目会持续更新收录以下内容: 1、Chrome玩法技巧 2、Chrome好用的插件推荐 3、Chrome使用问题解答 4、待补充 因为Chrome真的很强大,有很多值得挖掘的地方,用的好,真的是一大利器,因此想不断学习挖掘Google Chrome,这是个长久之事,所以希望大家可以一起来。 大家有任何关于Chrome的使用技巧以及插件推荐,或者在使用中遇到问题,都可以联系我 ![我的微信](README.assets/%E6%88%91%E7%9A%84%E5%BE%AE%E4%BF%A1-1573115250690.jpg) 另外,PDF文档会不断地更新,这是为了方便大家下载下来本地学习,请持续关注,...
Java
UTF-8
1,291
3.078125
3
[]
no_license
package com.zeulb.textbuddy; import static org.junit.Assert.*; import java.io.PrintWriter; import org.junit.Before; import org.junit.Test; public class TextContainerTest { private static final String fileName = "testFile.txt"; public boolean insertToFile(String string) { try { ...
Markdown
UTF-8
1,120
2.96875
3
[]
no_license
Chocolate Cake is one of my favorite desserts. If I were to choose any dessert to eat, I would choose chocolate cake. Today, I am showing a simple recipie for kids to make chocolate cake at home. 2 cups white sugar 1 ¾ cups all-purpose flour ¾ cup unsweetened cocoa powder 1 ½ teaspoons baking powder 1 ½ teaspoons bak...
PHP
UTF-8
959
2.515625
3
[]
no_license
<?php /** * This file is part of the QualityPress package. * * (c) QualityPress * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace QualityPress\QCommerce\Component\Association\Factory; /** * Factory * * @author Quality...
Java
UTF-8
597
3.03125
3
[ "Unlicense" ]
permissive
package github.com.helbertrios.demo.javase.passagemparametro; public class PassagemParametroValor { public static void main(String[] args) { int i = 1; changePrimitivo(i); System.out.println(i); // 1 Integer I = 1; changePrimitivo(I); System.out.println(I); // 2 int j = 1; changePrimitivo(j);...
TypeScript
UTF-8
6,514
2.5625
3
[ "Apache-2.0" ]
permissive
import { generateTypeDef, dataTreeTypeDefCreator, flattenDef, getFunctionsArgsType, } from "utils/autocomplete/dataTreeTypeDefCreator"; import { DataTreeWidget, ENTITY_TYPE, EvaluationSubstitutionType, } from "entities/DataTree/dataTreeFactory"; import { entityDefinitions } from "utils/autocomplete/Entity...
C#
UTF-8
1,589
2.53125
3
[]
no_license
using System.Collections.Generic; using System.Linq; using HtmlAgilityPack; using Domain.Calendar.Parser.Columns.Exceptions; using Domain.Calendar.Parser.Dto; using Domain.Calendar.Parser.Interfaces; namespace Domain.Calendar.Parser.Services { public class EarningsCalendarParser : IParseEarningsCalendar { ...
Markdown
UTF-8
2,545
3.203125
3
[ "MIT" ]
permissive
# **Cheat Sheet** ## Table of Contents * [Command Line](#Command-Line-/-Terminal) * [Git](#Git) ## **Command Line / Terminal** ### Keyboard Shortcuts * <kbd>TAB</kbd> - Attempts to autocomplete the directory or file name you are typing. If there are >1 files that fit the letters you have typed, will display all ma...
Ruby
UTF-8
203
2.875
3
[]
no_license
module Utilities class UniqueKeyGenerator ALPHANUMERIC = [*'a'..'z', *'A'..'Z', *0..9].freeze def self.generate length = 8 (0...length).map{ ALPHANUMERIC.sample }.join end end end
Python
UTF-8
62
2.953125
3
[]
no_license
#Dictionary n = {"chicken":'4',"mutton":5} print n.values()
Markdown
UTF-8
3,335
3.34375
3
[ "MIT" ]
permissive
--- layout: essay type: essay title: Scratch, Python, Java, Javascript - My Programming Progression # All dates must be YYYY-MM-DD format! date: 2018-08-30 labels: - Javascript - Learning - Software Engineering --- <img class="ui small center circular floated image" src="../images/scratch.png"> When I decided t...
Python
UTF-8
1,134
3.078125
3
[]
no_license
#!/bin/python3 import sys import math def sq_root(nos): sq_root_nrst = sq_min(nos) sq_root_nrst_ma = max_sqroot(nos) for nums in range(sq_root_nrst,sq_root_nrst_ma): square=nums*nums #print(square) str_square=int(''.join(list(str(square))[0::2])) nostr='' for no in...
Java
UTF-8
3,007
2.921875
3
[]
no_license
package karting; public class Vozilo { private double maksBrzina; private double ubrzanje; private double upravljivost; private String ime; private double trenutnaBrzina; private double pomMaksBrzina; private double duzinaPuta(double V0, double t, double a) { return (V0 * t) + (a * Math.pow(t, 2)) / 2; ...
Markdown
UTF-8
2,578
2.75
3
[]
no_license
## Contributing changes to the Synchronet Source Repository Merge requests are considered and accepted at [gitlab.synchro.net](https://gitlab.synchro.net). Do not submit pull/merge requests in the Synchronet *mirror projects* on github.com or gitlab.com; they won't be considered. When submitting merge requests to exi...
Python
UTF-8
445
3.234375
3
[ "MIT" ]
permissive
from Rationals.RationalType import Rational def harmonic_series(n): H = Rational(1,1) ctr = 2 while True: yield H if ctr > n: break H += Rational(1,ctr) ctr += 1 def alternating_harmonic_series(n): H = Rational(1,1) ctr = 2 alt = 1 while ...
Java
UTF-8
146
2.703125
3
[]
no_license
public class PineApple implements Fruit { @Override public void smeel() { System.out.println("Smels like PineApple"); } }
JavaScript
UTF-8
1,187
2.765625
3
[]
no_license
import anecdotesService from '../services/anecdotes' const reducer = (state = [], action) => { switch (action.type) { case 'INITIALIZE': return action.data case 'UPDATE': const updatedAnecdote = action.data return state.map(item => item.id === updatedAnecdote.id ? updatedAnecdote : item) ...
JavaScript
UTF-8
1,837
2.75
3
[]
no_license
function Student (name,email) { let _name = name; let _email = email; this.getName= () => _name; this.getEmail=() => _email; let homworkRes = []; this.addHomworkResult = function(topic,success) { homworkRes.push({topic:topic, success:success}) } this.getHomworkResult = () => homw...
JavaScript
UTF-8
958
2.59375
3
[]
no_license
var TweetCompose = function (form) { this.$textArea = $(form).find("#tweet-content"); this.content = this.$textArea.val(); this.$mention = $(form).find("#tweet-mentions"); this.mentioned = this.$mention.val(); this.$form = $(form); this.handleSubmit(); }; TweetCompose.prototype.handleSubmit = function ()...
Java
UTF-8
397
2.65625
3
[ "MIT" ]
permissive
package com.javaxator.patterns.visitor; public class SteeringComponent extends AbstractComponent { @Override public String getName() { return "Steering component"; } @Override public void acceptVisitor(ShipComponentVisitor visitor) { visitor.visit(this); } @Override p...
Python
UTF-8
641
3.203125
3
[]
no_license
#!/usr/bin/env python3 from itertools import permutations import sys def solve(A: int, B: int, C: int): m = 0 for n1, n2, n3 in permutations([A, B, C]): exp1 = "%d+%d%d" % (n1, n2, n3) exp2 = "%d%d+%d" % (n1, n2, n3) m = max(m, eval(exp1), eval(exp2)) print(m) def main(): def...
Markdown
UTF-8
4,108
3.03125
3
[ "MIT" ]
permissive
--- title: "Sawing in VR" permalink: /portfolio/vr-mesh-cutting/ date: 2020-10-15 excerpt: "This is a tech demo in VR environment where objects can be cut as the user does." header: image: /assets/images/vrMeshCut_main_wide.png teaser: /assets/images/vrMeshCut_play_1.gif company: "Academic Project" engine: "Unity" ...
Java
UTF-8
953
2.421875
2
[]
no_license
package ru.geekbrains.simple.market.controllers; import lombok.RequiredArgsConstructor; import org.springframework.web.bind.annotation.*; import ru.geekbrains.simple.market.beans.Cart; import ru.geekbrains.simple.market.dto.CartDto; @RestController @RequestMapping("api/v1/cart") @RequiredArgsConstructor public class ...
C
UTF-8
11,815
2.59375
3
[ "BSD-2-Clause" ]
permissive
#include <dirent.h> #include <errno.h> #include <fcntl.h> #include <stdbool.h> #include <stddef.h> #include <stdio.h> #include <string.h> #include <unistd.h> #include <sys/mman.h> #include <sys/time.h> #include <sys/xattr.h> #include <fuse.h> #include <ulockmgr.h> #define UNUSED(x) (void)(x) #define CHECK(call) ({in...
Python
UTF-8
455
3.71875
4
[ "MIT" ]
permissive
from collections import deque class Queue(object): def __init__(self): self._queue = deque() def size(self): return len(self._queue) def is_empty(self): return len(self._queue) == 0 def enqueue(self, value): self._queue.append(value) def deque(self): try...
Shell
UTF-8
3,024
3.15625
3
[ "Apache-2.0" ]
permissive
#!/bin/bash # builds intermediate interp tables (geo and taxonomy). NOTE: make sure the epsg-hsql jar is the right version for the latest release of occurrence-hive! log () { echo $(tput setaf 6)$(date '+%Y-%m-%d %H:%M:%S ')$(tput setaf 14)$1$(tput sgr0) } #SONAR_REDIRECT_URL=http://repository.gbif.org/repository/g...
Markdown
UTF-8
3,217
2.546875
3
[]
no_license
--- published: true title: Entregan 36 millones de pesos en apoyos a adultos mayores y jefas de familia twitt: ■ Distribuyeron cheques a 115 abuelitos de los municipios de Zacatecas y Guadalupe author: "RAQUEL OLLAQUINDIA " location: Local category: Portada layout: posts --- ![](http://i.imgur.com/E7QfIVYm.jpg) ■ Tra...
TypeScript
UTF-8
2,127
3.140625
3
[]
no_license
/// <amd-module name="viewportCollision"/> // amd-module directive only required for OneRf. // TODO: 8607647 - Update OneRf build task to add this directive automatically. import * as HtmlExtensions from 'htmlExtensions'; /** * Determines whether or not an HTML Element collides with the edges of the viewport (is par...
Markdown
UTF-8
1,461
2.671875
3
[]
no_license
--- layout: post category: blog published: true title: 'Lukáš Kolářík: Špatný exekuční řád poškozuje celou naši společnost [VIDEO]' date: '2021-08-23' author: Piráti Jihočeský kraj image: 2021/kolis-video-exekuce.png youtubeVideoId: XhctoRHiGnI description: 'Obchodníci s chudobou nesmějí dál vydělávat na neštěstí lid...
Python
UTF-8
11,366
2.75
3
[]
no_license
""" ObjectId: used to generate Id Flask: Allow template functionality Pymongo: Allows interaction between python and MongoDB """ import os from flask import Flask, render_template, redirect, request, url_for from flask_pymongo import PyMongo from bson.objectid import ObjectId from os import path if path.exists("env.py...
JavaScript
UTF-8
479
4.09375
4
[ "MIT" ]
permissive
function hoistingWithDeclaration() { var x = 5; var y; console.log("x is " + x + " and y is " + y); y = 7; } hoistingWithDeclaration(); function hoistingWithDeclarationAfterUse() { var x = 5; console.log("x is " + x + " and y is " + y); var y = 7; } hoistingWithDeclarationAfterUse(); ...
JavaScript
UTF-8
333
2.578125
3
[]
no_license
document.addEventListener("DOMContentLoaded", function (event) { console.log("DOM fully loaded and parsed"); var isle = document.getElementById('islands'); var fade = document.getElementsByClassName('fade'); fade.addEventListener('mouseover', function () { fade.style.transition = "opacity 1s"...
C++
UTF-8
790
2.71875
3
[]
no_license
#pragma once #include <cstdint> #include <cstring> #include <vector> #include <glm/vec2.hpp> #include "geom.h" struct ImageShape { uint8_t id; geom::Bounds<int> bounds; ImageShape() :id(0), bounds() { } ImageShape(uint8_t id, int x, int y) :id(id), bounds(x, y) { } }; class ...
Shell
UTF-8
1,767
2.6875
3
[]
no_license
#!/bin/bash outdir=outputs mkdir $outdir domainArray=("recipes" "housing" "basketball" "blocks" "calendar" "publications" "restaurants" "socialnetwork") outdir1=${outdir}/out1 mkdir $outdir1 for domain in ${domainArray[*]}; do echo $domain python preprocess_1.py overnight-lf/ $domain $outdir1 done java_out_...
C++
UTF-8
465
2.625
3
[]
no_license
#include "Reboot_to_boot.h" // the setup function runs once when you press reset or power the board void setup() { //reboot_setup(int delay, char pin, char flag).delay is the timer timeout for reboot,pin is which pin is for LED to set ,flag is for selecting/unselecting led functionality. // timer timeout for del...
SQL
UTF-8
868
3.09375
3
[]
no_license
 USE Employees DELETE FROM dbo.Employees DELETE FROM dbo.Shifts DELETE FROM dbo.Countries DBCC CHECKIDENT ('Employees.dbo.Employees',RESEED, 0) DBCC CHECKIDENT ('Employees.dbo.Shifts',RESEED, 0) DBCC CHECKIDENT ('Employees.dbo.Countries',RESEED, 0) INSERT INTO dbo.Shifts VALUES ('Morning',9,16) INSERT INTO dbo.Shi...
JavaScript
UTF-8
5,311
2.859375
3
[]
no_license
const HEADERS = { 'Content-Type': 'application/json;charset=utf-8', 'Access-Control-Allow-Origin': '*' }; const whereSpentInput = document.getElementById('where-spent'); const howMuchSpentInput = document.getElementById('how-much-spent'); const buttonAddEl = document.getElementById('button-add-el'); const mainList ...
TypeScript
UTF-8
1,481
2.5625
3
[]
no_license
import { Component, OnInit } from '@angular/core'; import { ConfigService } from './config.service'; import { HttpHeaders, HttpParams } from '@angular/common/http'; @Component({ selector: 'app-config', templateUrl: './config.component.html', styleUrls: ['./config.component.css'] }) export interface Config { h...
Python
UTF-8
4,821
2.75
3
[ "MIT" ]
permissive
import paramiko import time from optparse import OptionParser # Option Parer Menu parser = OptionParser(usage="useage: %prog -o (check|assign) -H (IP Address) -u (Username) -p (Password) -x (Port) -n (VLAN Number)", version="VLAN Swap 1.0") parser.add_option("-o", "--option", a...
PHP
UTF-8
3,243
2.625
3
[]
no_license
<?php namespace tests\unit\models; use app\models\ArraySplit; use app\models\User; class ArraySplitTest extends \Codeception\Test\Unit { public function testCanSplitArray() { $this->assertEquals( 4, ArraySplit::getSplitIndex(5, [5, 5, 1, 7, 2, 3, 5])); $this->assertEqu...
PHP
UTF-8
1,779
2.734375
3
[]
no_license
<?php namespace Chatbox\ApiAuth\Http\Controllers; use Chatbox\ApiAuth\Domains\User; use Chatbox\ApiAuth\Domains\UserServiceInterface; use Chatbox\ApiAuth\Http\AuthRequest; use Chatbox\ApiAuth\Http\Request\AuthToken; use Chatbox\ApiAuth\Http\Request\ProfileForRegister; use Chatbox\ApiAuth\Http\Request\ProfileForUpdate; ...
PHP
UTF-8
1,492
2.828125
3
[]
no_license
<?php include_once '../abstract/Abstrata.php'; include_once '../iCRUD/iCRUD.php'; class Foto extends Abstrata implements iCRUD { //CRIANDO OS ATRUBUTOS private $id; private $nome; private $foto; function getId() { return $this->id; } function getNome() { return $this-...
Python
UTF-8
1,414
2.90625
3
[]
no_license
import copy import re def parse(line): m = re.findall(r"\<([0-9,-]+)\>", line) p, v, a = map(lambda x: [int(k) for k in x.split(",")], m) return [p, v, a] def step(particle): particle[1][0] += particle[2][0] particle[1][1] += particle[2][1] particle[1][2] += particle[2][2] particle[0][0]...
C++
UTF-8
555
2.765625
3
[]
no_license
#pragma once #include <iostream> #include <string> using namespace std; #include <iomanip> #include "vehicle.h" vehicle::vehicle (int myr, string mname, int ntires){ model_year = myr; model_name = mname; num_of_tires = ntires; } void vehicle::init_class_vars( int myear, string mname, int ntires){ model_...
Java
UTF-8
3,125
2.453125
2
[]
no_license
package com.example.tradestorage; import java.time.LocalDate; import java.util.List; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import com.example.tradestorage....
JavaScript
UTF-8
3,345
2.859375
3
[]
no_license
const Command = require('../commands.js').Command; const Discord = require('discord.js'); module.exports = class Admin extends Command { /** * @param {string} prefix: the prefix for this instance */ constructor(prefix) { let hooks = ["admin", "admins"]; super(prefix, hooks); this.name = "Admin"; // File s...
Markdown
UTF-8
969
2.78125
3
[ "MIT" ]
permissive
# Avatar Creator ## Aim/Purpose To make our own customised avtaar ## Short description of package/script - Here using the library for avatar we can customize each and every thing from background to face parts.Here we can select the background colour and shape then for face parts we can choose shapes of nose, eyes ...
Markdown
UTF-8
2,764
2.625
3
[ "CC-BY-4.0", "MIT" ]
permissive
--- title: パック() - Azure データ エクスプローラー |マイクロソフトドキュメント description: この記事では、Azure データ エクスプローラーでの pack() について説明します。 services: data-explorer author: orspod ms.author: orspodek ms.reviewer: rkarlin ms.service: data-explorer ms.topic: reference ms.date: 02/13/2020 ms.openlocfilehash: a7b43be96f272ab929434f10cac910bd4072e650 m...
PHP
UTF-8
4,063
2.515625
3
[]
no_license
<?php namespace Scoris\Contact\Repositories\Eloquent; use Scoris\Contact\Repositories\Interfaces\ContactCategoryInterface; use Scoris\Support\Repositories\Eloquent\RepositoriesAbstract; use Scoris\Contact\Models\ContactCategoryParent; use Scoris\Contact\Models\ContactCategory; class ContactCategoryRepository extends ...
C
UTF-8
3,003
2.9375
3
[]
no_license
#include<stdio.h> #define ll long long int #define get(n) ll n; if(scanf("%lld", &n)) #define gets(n) char n ; if(scanf("%c", &n)) #define show(n) printf("%lld\n", n) #define shows(n) printf("%c\n",n) #define loop(a,b) for( int i=a ; i<b ; i++) #define eloop(a,b) for(int i=a ; i<=b ; i++) void merge(ll arr[] , ll a...
Shell
UTF-8
1,503
2.84375
3
[]
no_license
#!/usr/bin/env bash PATH='/opt/conda/bin:/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' if [ ! -d "imgs" ]; then # get celeba data DEBIAN_FRONTEND=noninteractive apt-get -yq update DEBIAN_FRONTEND=noninteractive apt-get -yq install wg...
Python
UTF-8
885
3
3
[]
no_license
g=open('output.txt','w') with open('A-small-attempt3.txt','r') as f : t=int(f.readline()) c=1 while True : l=[] m=[] x=int(f.readline()) for i in range(4): l.append(f.readline().split()) y=int(f.readline()) for i in range(4): ...
Java
UTF-8
443
1.84375
2
[]
no_license
package com.yingzi.center.manager.eo; import javax.persistence.Column; import javax.persistence.Comment; import javax.persistence.Table; @Table(name = "manager_area_code") @Comment("行政区域编码") public class AreaCode { @Column(columnDefinition = "编码") Integer code; @Column(columnDefinition = "父...
Markdown
UTF-8
3,913
2.90625
3
[]
no_license
# FixIT3160: IT Support Ticketing Software Project Implementation for University of Newcastle SENG3160 2019 **Authors:** Benjamin McDonnell, Jordan Maddock, Matthew Rudge, Kundayi Sitole Project now live on Heroku at https://fixit3160.herokuapp.com Project hosted on GitHub at https://github.com/benoz11/fixit3160 C...
JavaScript
UTF-8
966
3.234375
3
[]
no_license
import pointwise from './pointwise' import spPointwise from './spPointwise' import Sparse from './Sparse' import Complex from './Complex' import atan2 from './atan2' import abs from './abs' const log = pointwise(Math.log) const slog = spPointwise(Math.log) function clog(x) { if (x.im) { var theta = new Complex...
C#
UTF-8
693
2.921875
3
[]
no_license
using Saucar.Chess.Models; namespace Saucar.Chess.Tests.contexts { public class boardContext { protected int _column; protected int _row; protected Chessboard _board; public Models.Knight Knight; protected void Given_a_board(int row, int column) { _...
JavaScript
UTF-8
2,318
2.796875
3
[]
no_license
var kartta = L.map('kartta').setView([60.1733, 24.94], 14); L.tileLayer('https://api.mapbox.com/styles/v1/{id}/tiles/{z}/{x}/{y}?access_token=pk.eyJ1IjoibWFwYm94IiwiYSI6ImNpejY4NXVycTA2emYycXBndHRqcmZ3N3gifQ.rJcFIG214AriISLbB6B5aw', { maxZoom: 18, attribution: 'Map data &copy; <a href="https://www.openstreetmap.o...
Java
UTF-8
5,401
2.4375
2
[ "MIT" ]
permissive
package io.frictionlessdata.tableschema.beans; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.google.common.util.concurrent.AtomicDouble; import java.math.BigDecimal; import java.math.BigInteger; import java.util.Objects; import java.util.co...
TypeScript
UTF-8
1,869
2.625
3
[ "MIT" ]
permissive
import * as commander from "commander"; import { readFileSync } from "fs"; import { Parser } from "./Parser"; import { JiraApiConnector } from "./jira/JiraApiConnector"; import { FormatError } from "./errors"; import { checkForUpdates } from "./util/checkForUpdates"; import { Logger } from "./util/Logger"; import { han...
PHP
UTF-8
796
2.53125
3
[]
no_license
<?php require __DIR__ . "/vendor/autoload.php"; require_once('functions.php'); use Twilio\Rest\Client; $dotenv = Dotenv\Dotenv::create(__DIR__); $dotenv->load(); if ($_SERVER['REQUEST_METHOD'] === 'POST') { $message = $_REQUEST['Body'] ?? ''; $from = $_REQUEST['From'] ?? ''; if ($message !== '') { $acc...
Ruby
UTF-8
182
3.21875
3
[]
no_license
def compute(str1, str2) counter=0 min_length = [str1.length, str2.length].min i=0 while i<min_length do counter++ if not str1[i] == str2[i] i = i+1 end counter end
Python
UTF-8
201
4.0625
4
[]
no_license
# python arrays 2 cars = ["Ford","Audi", "Benz"] #loop through an array for x in cars: print(x) # adding an item cars.append("Honda") print(cars) # to remove an item cars.pop(0) print(cars)
Shell
UTF-8
408
2.734375
3
[]
no_license
#!/bin/sh root="$GOPATH/src" LIBS[0]="github.com/gorilla/websocket" LIBS[1]="github.com/astaxie/beego/logs" LIBS[2]="github.com/golang/protobuf/proto" LIBS[3]="github.com/garyburd/redigo/redis" LIBS[4]="labix.org/v2/mgo" echo ${LIBS[*]} for item in ${LIBS[*]} do if [ ! -e "$root/$item" ]; then echo "go ...
Ruby
UTF-8
2,192
2.875
3
[ "MIT" ]
permissive
require 'epilog' describe Epilog::UnificationGoal do let( :bound_value ){ "bound" } let( :bound_variable ){ Epilog::Variable.new( bound_value ) } let( :variable ){ Epilog::Variable.new } context "with left input unbound and right input is ground" do let( :goal ){ Epilog::UnificationGoal.new( variable, bound_var...