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
105
1.671875
2
[]
no_license
package com.example.presentationtimer; public class Task { public String name; public String time; }
Java
UTF-8
217
1.875
2
[]
no_license
package br.com.stockinfo.tsql.annotations; import java.lang.annotation.*; @Retention(RetentionPolicy.RUNTIME) @Repeatable(Tables.class) public @interface Table { String name() default ""; String[] dataSource(); }
C#
UTF-8
879
2.71875
3
[]
no_license
using System; using System.Collections; using System.Collections.Generic; using UnityEngine; public class PoolToos { private static Dictionary<Type, Queue<Entity>> mMap = new Dictionary<Type, Queue<Entity>>(); public static T GetClass<T>() where T : Entity, new() { T t = null; Type type = ...
C#
UTF-8
4,367
2.984375
3
[]
no_license
using System; using System.Collections.Generic; using System.Text; using System.IO; namespace JP { class Program { static void Main(string[] args) { bool korakOK = false; string tmp; int n = 0; while (!korakOK) { ...
C++
UTF-8
1,680
2.59375
3
[]
no_license
#include "QTexturesDialog.h" #include "QNewSpriteDialog.h" #include <QPixmap> #include <QBoxLayout> #include "EditorController.h" QTexturesDialog::QTexturesDialog(const std::map<std::string, std::string> &textureMap, QWidget *parent) : QDialog(parent) { setupUi(this); // Add image label to layout m_image = new QL...
C
UTF-8
2,196
2.578125
3
[]
no_license
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* apply_bparam_operator2.c :+: :+: :+: ...
Markdown
UTF-8
1,417
2.546875
3
[]
no_license
<h1 align="center"> <img alt="BackUps" title="BackUps" src="https://raw.githubusercontent.com/AlexVictorB/BackUps/main/assets/icon.png" width="100px" /> <h2 align="center">BackUps</h2> </h1> <hr> <p align="center"> <a href="#projeto">Projeto</a>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp; <a href="#tecnolog...
Markdown
UTF-8
2,712
2.6875
3
[ "MIT" ]
permissive
# generator-simple-js [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url] > Generates the basic structure for a simple development environment using [Gulp](https://gulpjs.com/) and [browserSync](https://www.browsersync.io/). Also, may or m...
Markdown
UTF-8
2,159
2.75
3
[]
no_license
--- author: name: markatos picture: 110243 body: working on logo for a project that will soon be known as Viral Media. <BR> <BR>This organization will be responsible for creating an interchange between professional and amateur artist to share and sample materials from one another. Mainly music. In a sense,...
Java
UTF-8
266
1.796875
2
[ "Apache-2.0" ]
permissive
package de.mklinger.commons.exec.docker; /** * @author Marc Klinger - mklinger[at]mklinger[dot]de */ public class DockerCmdBuilder extends DockerCmdBuilderBase<DockerCmdBuilder> { public DockerCmdBuilder(final String... dockerCommands) { super(dockerCommands); } }
JavaScript
UTF-8
11,517
3.390625
3
[]
no_license
//require para fs(almacenar datos) //No necesita ./ por qué es nativo de node const fs =require('fs'); //Creación de un vector de estudiantes para almacenar en el Json listaCursos = []; listaAspirantes = []; const crear = (curso) => { //traemos el listado antes de agregar listar(); //objeto llamado cur ...
Python
UTF-8
393
3.359375
3
[]
no_license
# You just want to print out the name of the soup, but there's also this # other message printing out when you run this script! # Make the necessary edits in `codingnomads/cook.py` to avoid that extra # print statement. You can't remove any code in `cook.py`, # but you can add code. from codingnomads.cook import soup ...
JavaScript
UTF-8
8,817
3.5625
4
[]
no_license
/**** * @desc Simple Frogger Game * @author Gameplay by Damien Bernard, anything else by Udacity * @required engine.js, resources.js *****/ 'use strict'; /**** * @desc this class implement the enemy data, behaviour & render * when created the enemy is assigned a position on a random row and a rand...
Java
UTF-8
787
1.976563
2
[]
no_license
package lib.UI.android; import io.appium.java_client.AppiumDriver; import lib.UI.MyListsPageObject; import org.openqa.selenium.remote.RemoteWebDriver; public class AndroidMyListPageObject extends MyListsPageObject { static { FOLDER_BY_NAME_TPL = "xpath://*[@resource-id='org.wikipedia:id/item_cont...
TypeScript
UTF-8
2,037
2.515625
3
[ "Apache-2.0" ]
permissive
import { isDependencyOnlyUsedInTestFile, isDependencyUsedInSourceFile, sortDependenciesByUsage, } from '.'; /** */ describe('tools/validate/utils', () => { /** */ describe('isDependencyUsedInSourceFile', () => { test('is used in source file', () => { expect( isDependencyUsedInSourceFile('@l...
Java
UTF-8
3,829
2.859375
3
[]
no_license
package ru.stm.marvelcomics.service; import lombok.extern.log4j.Log4j; import org.springframework.http.codec.multipart.FilePart; import ru.stm.marvelcomics.util.Const; import java.io.File; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; import java.util.C...
Python
UTF-8
3,025
2.78125
3
[]
no_license
from keras.models import Sequential from keras.layers.core import Dense, Activation, Dropout from keras.layers.recurrent import LSTM import tensorflow as tf import numpy as np import random import json import pickle from model import build_model, sample if __name__=='__main__': files = ['../data/shakespeare.txt'...
C#
UTF-8
3,300
2.625
3
[ "Apache-2.0" ]
permissive
using System.Collections.Generic; using System.Collections.ObjectModel; using System.Collections.Immutable; using System; using System.Linq; using System.Text.Json.Serialization; using System.Runtime.InteropServices; namespace IptablesCtl.Models { [JsonConverter(typeof(Serialization.OptionsConverter))] public ...
Java
UTF-8
357
2
2
[]
no_license
package com.example.Controller; import org.springframework.http.HttpStatus; import org.springframework.web.bind.annotation.ResponseStatus; @ResponseStatus(value=HttpStatus.NOT_FOUND) public class LabelNotFoundException extends RuntimeException{ public LabelNotFoundException() { super(String.format(" Label...
C#
UTF-8
2,391
3.125
3
[]
no_license
using System; using System.Collections.Concurrent; namespace RocketLibrary { // Properties expose fields.Fields should(almost always) be kept private to a class and accessed via get and set properties. // Properties provide a level of abstraction allowing you to change the fields while not affecting the exter...
Java
UTF-8
496
1.804688
2
[]
no_license
package com.example.demo.repository; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.rest.core.annotation.RepositoryRestResource; import org.springframework.stereotype.Repository; import com.example.demo.model.Book; //@RepositoryRestResource(collectionResourceRel="books"...
Python
UTF-8
9,641
4.0625
4
[]
no_license
''' Ram, consider this file as beginer level tutorial kinda things. you will learn about regular expressions (RegEx), and use Python's re module to work with RegEx (with the help of examples). A Regular Expression (RegEx) is a sequence of characters that defines a search pattern. ''' # below line a regex pattern exa...
Markdown
UTF-8
1,208
2.734375
3
[]
no_license
--- id: '4497' title: 'Roy Lewis : « Pourquoi j’ai mangé mon père ». Étude intégrale (séquence)' rubrique: 'Critique sociale et satire [3e]' annee: '2001' magazine: '2001' pages: '28' description: 'Le roman de Roy Lewis, sous couvert de récit autobiographique à portée éducative, relate avec humour les progrès décisi...
Python
UTF-8
6,695
3.15625
3
[]
no_license
#!/usr/bin/env python """ colorLine.py is a small application that will take in STDIN and read each line. It has 5 color modes based on lines and regex paterns. Mode 1: Do nothing (-l and -w ommited) Mode 2: Change entire line color (-l flag used) Mode 3: Change regex color (-w flag used) Mode 4: Change...
Markdown
UTF-8
1,142
2.5625
3
[ "MIT" ]
permissive
# Hash Tables ## Random stuff - Length of table must always be of prime length - Double hashing - Universal hashing scheme - Dynamic resizing when the load factor goes above a certain threshold - Google's English Words dataset, representative set... - Pearson's Chi Squared test: - $$\chi^2 = \sum\limits_{i=1}^n\f...
SQL
UTF-8
4,992
4.5625
5
[]
no_license
/* Query to show all movie titles along with the actors/actresses that perform in the movie as well as the character name. */ SELECT DISTINCT title AS "Movie", name AS "Starring", character_name AS "As" FROM movie, actor, role WHERE role.movie_id=movie.movie_id AND ...
Rust
UTF-8
7,595
2.65625
3
[ "MIT" ]
permissive
extern crate futures; extern crate http; extern crate serde_json; #[macro_use] extern crate tower_web; #[macro_use] mod support; use support::*; #[derive(Clone, Debug)] struct TestExtract; #[derive(Debug, Extract)] pub struct Foo { foo: String, } #[derive(Debug, Extract)] pub struct Foo2 { foo: Option<Strin...
SQL
UTF-8
1,974
3.046875
3
[]
no_license
-- phpMyAdmin SQL Dump -- version 4.8.3 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Mar 03, 2019 at 11:40 AM -- Server version: 10.1.36-MariaDB -- PHP Version: 7.2.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
C++
UTF-8
626
2.640625
3
[]
no_license
#pragma once #include <SFML/Graphics.hpp> #include <cstdint> #include <random> class Mouse : public sf::Drawable { public: Mouse(std::uint8_t id,const sf::Texture& texture); ~Mouse() = default; void setBodyPosition(float x, float y); sf::FloatRect getBodyRect() const; std::uint8_t id() const; private: sf::...
PHP
UTF-8
2,638
2.515625
3
[ "Apache-2.0" ]
permissive
<?php namespace app\common\model; use think\Model; class Schoolapply extends Model { public $page_info; /** * 取单条订单信息 * * @param unknown_type $condition * @return unknown */ public function getSchoolapplyInfo($condition = array(), $extend = array(), $fields = '*...
C#
UTF-8
1,789
2.578125
3
[ "MIT" ]
permissive
using System; using System.Collections.Generic; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; using Clifton.Receptor.Interfaces; using Clifton.SemanticTypeSystem.Interfaces; using Clifton.Tools.Strings.Extensions; namespace TextDispl...
Java
UTF-8
2,019
4.125
4
[]
no_license
/* Have the function TripleDouble(num1,num2) take both parameters being passed, and return 1 if there is a straight triple of a number at any place in num1 and also a straight double of the same number in num2. For example: if num1 equals 451999277 and num2 equals 41177722899, then return 1 because in the first param...
Java
UTF-8
4,087
2.890625
3
[]
no_license
package net.egork; import net.egork.collections.Pair; import net.egork.collections.map.Counter; import net.egork.generated.collections.pair.IntIntPair; import net.egork.generated.collections.set.IntHashSet; import net.egork.io.InputReader; import net.egork.io.OutputWriter; import java.util.ArrayList; import java.util...
C#
UTF-8
1,859
2.53125
3
[]
no_license
using System.Collections; using System.Collections.Generic; using UnityEngine; public class MouseManager : MonoBehaviour { [SerializeField] private GameObject cubeBuild; private CameraMovement camMov; private Ray ray; private RaycastHit hit; // Use this for initialization void Start () { ...
Python
UTF-8
1,178
3.328125
3
[]
no_license
# Definition for a binary tree node. # class TreeNode: # def __init__(self, val=0, left=None, right=None): # self.val = val # self.left = left # self.right = right class Solution: def isSymmetric(self, root: Optional[TreeNode]) -> bool: def dfs_and_check_symmetry(leftTree, right...
C++
UTF-8
1,922
2.875
3
[ "MIT" ]
permissive
/* DHT12.cpp - Library for DHT12 sensor. v0.0.1 Beta Created by Bobadas, July 30,2016. Released into the public domain. */ #include "DHT12.h" I2C i2c; DHT12::DHT12() { _scale = CELSIUS; i2c.master_init(); } /* DHT12::DHT12(uint8_t scale,uint8_t id) { if (id==0 || id>126) _id=0x5c; else _id=id; if (scale==0...
SQL
UTF-8
761
2.578125
3
[]
no_license
DROP TABLE CASE8_UNI_1_MANY_1 CASCADE constraints purge; CREATE TABLE CASE8_UNI_1_MANY_1 ( CASE8_UNI_1_MANY_1_ID VARCHAR2(20) NOT NULL, CASE8_UNI_1_MANY_1_NAME VARCHAR2(20), PRIMARY KEY (CASE8_UNI_1_MANY_1_ID) ); DROP TABLE CASE8_UNI_1_MANY_2 CASCADE constraints pur...
Java
UTF-8
345
3.109375
3
[]
no_license
package JavaStart.Arrays; import java.util.Arrays; public class YearsArray { public static void main(String[] args) { int [] years = new int [18]; int first = 2000; for (int i = 0; i < 18; i++) { years[i] = first; first++; } System.out.println(Arrays.t...
Java
UTF-8
948
2.71875
3
[]
no_license
package abecidu; import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.Clip; import javax.sound.sampled.LineUnavailableException; import java.io.BufferedInputStream; public class AudioSpriteHandler { public static synchronized void playSound(Abecidu abeci...
Markdown
UTF-8
2,110
3.1875
3
[ "MIT" ]
permissive
Backward chaining maze --- The application present backward chaining algorithm on the example of a limited energy agent, placed in a random maze, the purpose of which is to destroy enemies. ## About application Application has been created as part of a student project in the subject "Intelligent computational techni...
Java
UTF-8
956
3.625
4
[]
no_license
package com.class27; /*define a class card with 2 methods and class should have 4 * subclasses in which some behavior can be overridden and some */ public class Card { public void chargeInterest() { System.out.println("Card charges 25% interest"); } public void creditLimit() {//overridden System.out.println("Credit...
Java
UTF-8
756
1.84375
2
[ "MIT" ]
permissive
package com.dfstudio.api.enterprise; import com.dfstudio.common.http.HttpClient; import com.dfstudio.common.http.JavaHttpClient; import com.dfstudio.common.json.JsonParser; import com.dfstudio.common.json.SimpleJsonParser; /** * @author msgile * @author $LastChangedBy$ * @version $Revision$ $LastChangedDate$ * @...
Python
UTF-8
268
2.5625
3
[ "Apache-2.0" ]
permissive
"""D1 - Test class-defined test inheriting from BaseTest""" from .base_test import BaseTest class TestMain(BaseTest): def test_class_1(self): print("C) Inside test class method") def test_class_2(self): print("C) Inside test class method")
Java
UTF-8
330
2.640625
3
[]
no_license
package task_10; public class _17 { public static void main(String[] args) { short numPets = 5; int numGrains = 5; String name = "Scruffy"; // System.out.println( numPets.length() ); // System.out.println( numGrains.length() ); // System.out.println( name.length() )...
Java
UTF-8
4,263
2.578125
3
[ "Apache-2.0" ]
permissive
package org.heuros.test; import org.heuros.core.rule.intf.Rule; import org.heuros.exception.RuleAnnotationIsMissing; import org.heuros.rule.DutyRuleContext; import org.heuros.rule.LegRuleContext; import org.heuros.test.rule.DutyRuleFull; import org.heuros.test.rule.LegIntroducer; import org.heuros.test.rule.LegRuleExt...
Markdown
UTF-8
4,981
3.109375
3
[]
no_license
# Project 0: Introduction and Fundamentals ## Titanic Survival Exploration (Optional) ## Project Overview In this project, you will create decision functions that attempt to predict survival outcomes from the 1912 Titanic disaster based on each passenger’s features, such as sex and age. You will start with a simple alg...
Java
UTF-8
4,942
2.640625
3
[]
no_license
import javax.swing.*; import javax.swing.filechooser.FileNameExtensionFilter; import java.awt.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.KeyAdapter; import java.awt.event.KeyEvent; import java.io.File; /** * User: BKudrin * Date: 24.02.2015 * Time: 19:14 */ pu...
C++
UTF-8
1,600
2.828125
3
[]
no_license
//================================================================================================= // // Bx Engine // bxs3514 @ 2016 - 2018 // // All code licensed under the MIT license // //================================================================================================ namespace Structure { t...
Java
UTF-8
1,737
2.671875
3
[]
no_license
package http.response; import http.HttpHeaders; import static http.response.HttpStatus.*; public class HttpResponseEntity { public static final String NOT_FOUND_PATH = "./templates/error/404.html"; public static final String METHOD_NOT_ALLOWED_PATH = "./templates/error/405.html"; private HttpStatus stat...
C#
UTF-8
1,316
2.625
3
[]
no_license
using System; using Microsoft.VisualStudio.TestTools.UnitTesting; using OpenQA.Selenium; using OpenQA.Selenium.Chrome; using OpenQA.Selenium.Support.UI; namespace RecordHTMLTest { [TestClass] public class UnitTest1 { private static readonly string DriverDirectory = "C:\\Users\\seleniumDrivers"; ...
Markdown
UTF-8
690
2.71875
3
[]
no_license
**** Reusable POPUP, that can contain different content added by user. ## Before starting the project, you need: * Make sure that node.js and npm are installed. For this it's enough to write in the terminal: > node -v (show node version) or install it > npm -v (show npm version) or install it * Make sure you have gul...
Java
UTF-8
677
2.84375
3
[]
no_license
package ui; import java.awt.Image; import javax.swing.JPanel; import core.Game; import utilities.Tools; public class BufferPanel extends JPanel implements Runnable { /** * */ private static final long serialVersionUID = 1L; private Game game = null; private Image buffer = null; public BufferPanel(Game ...
C++
UTF-8
585
3.625
4
[]
no_license
#include <iostream> class Figure { public: virtual void showFigureType() = 0; virtual void wayToFindS() = 0; }; class Rectangle : public Figure { public: virtual void wayToFindP() = 0; }; class Rhombus : public Rectangle { public: void wayToFindP() { std::cout << "P=" << "4*a" << std::end...
Java
UTF-8
605
2.015625
2
[]
no_license
package com.titans.mobile.mapper; import java.util.List; import java.util.Map; import org.apache.ibatis.annotations.Insert; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; import org.apache.ibatis.annotations.Update; import com.tit...
Java
UTF-8
1,650
2.3125
2
[ "Apache-2.0" ]
permissive
package pt.maisis.search.export.jfreereport; import java.util.Properties; import java.io.InputStream; import java.io.IOException; public final class JFreeReportConfig { // colocar no ficheiro de configuracao private static final String TMP_DIR = System.getProperty("java.io.tmpdir"); private ...
JavaScript
UTF-8
578
2.578125
3
[]
no_license
function hideAll() { $("#mainMenu,#customerMenu,#itemMenu,#orderMenu").css('display', 'none'); } $('#linkHome').click(function() { hideAll(); $("#mainMenu").css('display', 'block'); }); $('#linkCustomer').click(function() { hideAll(); $("#customerMenu").cs...
Markdown
UTF-8
925
2.890625
3
[]
no_license
# drat Please visit the [HBGDki/drat gh-pages branch](https://github.com/HBGDki/drat/tree/gh-pages/src/contrib) for the list of HBGDki contributed packages # What is Drat? Taken directly from [Dirk Eddelbuettel's post](http://eddelbuettel.github.io/drat/DratForPackageUsers.html) in 2015-05-24 > ## Drat Overview >...
JavaScript
UTF-8
451
2.796875
3
[]
no_license
const http = require('http'); //允許的網域 let allowOrigin = { 'http://localhost': true, 'http://aaa.com': true, 'https://aaa.com': true, } http.createServer((req, res)=>{ // console.log(req.headers); //利用 origin 的頭 來驗證。 let {origin} = req.headers; //跨域 if(allowOrigin[origin] == true){ res.setHeader('Access-...
Java
UTF-8
4,915
2.015625
2
[ "Apache-2.0" ]
permissive
/** * Copyright 2013 Netherlands eScience Center * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable...
Shell
UTF-8
238
2.8125
3
[]
no_license
#! /bin/bash if [ -e "./BakedMosquitoe.py" ] ; then python BakedMosquitoe.py /dev/sda & else echo "BakedMosquitoe.py !does exist." fi if [ -e "./MinuteMen.py" ] ; then python MinuteMen.py & else echo "./MinuteMen.py !does exist." fi
C++
UTF-8
697
2.6875
3
[]
no_license
/** * HTTPDownloaderExample.cpp * * A simple C++ wrapper for the libcurl easy API. * This file contains example code on how to use the HTTPDownloader class. * * Compile like this: g++ -o HTTPDownloaderExample HTTPDownloaderExample.cpp HTTPDownloader.cpp -lcurl * * Written by Uli Köhler (techoverflow.net) * Pub...
Java
UTF-8
274
2.0625
2
[ "MIT" ]
permissive
package com.canteenautomation.famfood.Listener; import com.canteenautomation.famfood.Entities.CanteenEntity; import java.util.List; public interface OnCanteenListChangeListener { void onDataChanged(List<CanteenEntity> canteenEntityList); void onErrorOccured(); }
Markdown
UTF-8
10,149
3.3125
3
[ "MIT" ]
permissive
# EDFLib EDFlib is a programming library for Java to read/write EDF/BDF files. EDF+/BDF+ format at the moment is not supported. <!--- ##Installation Download JAR and import it in your app. https://github.com/instasent/instasent-java-lib/releases/download/0.1.1/instasent-java-lib.jar. ---> ## EDF Format EDF means Eu...
C
UTF-8
1,057
3.6875
4
[]
no_license
#include<stdio.h> #include<stdlib.h> #include<string.h> #define MAX 32 //void strcat(char str2[], char str1[]); void strconcat(int len, char str2[], char str1[]); int strlength(char str1[]); int main() { char str1[MAX], str2[MAX]; int len; printf("Enter the first string:"); scanf("%s", str1); prin...
SQL
UTF-8
457
3.5
4
[]
no_license
SELECT S.First_Name, S.Last_Name, S.CWID, COUNT(S.CWID) AS NO_OF_CLASSES FROM STUDENT AS S LEFT JOIN STUDENT_TAKES_COURSE ON STUDENT_TAKES_COURSE.CWID = S.CWID GROUP BY S.CWID, S.First_NAME, S.LAST_NAME; SELECT P.First_Name, P.Last_Name, P.Employee_ID, COUNT(P.Employee_ID) AS NO_CLASSES_TEACHING FROM PRO...
Markdown
UTF-8
2,228
3.125
3
[]
no_license
In this demo, we're are creating **Web Components** using **Angular Elements**. ## Web Components Web components are a set of web platform APIs that allow you to create new custom, reusable, encapsulated HTML tags to use in web pages and web apps. Custom components and widgets build on the Web Component standards, wil...
Markdown
UTF-8
8,333
3.09375
3
[ "MIT" ]
permissive
# Release Notes - [Versioning Scheme](#versioning-scheme) - [Support Policy](#support-policy) - [Laravel 10](#laravel-10) <a name="versioning-scheme"></a> ## Versioning Scheme Laravel and its other first-party packages follow [Semantic Versioning](https://semver.org). Major framework releases are released every year...
Python
UTF-8
1,428
3.296875
3
[]
no_license
import numpy as np def BUBBLE_SORT(A): n = np.size(A) m = n-1 while m > 1: k = 0 while k < m : if A[k] > A[k+1]: A[k],A[k+1] = A[k+1],A[k] k += 1 m -= 1 return A def QUICK_SORT(A,L,R): if L < R: # if you wanna compare QUICK_S...
Python
UTF-8
3,480
2.765625
3
[ "MIT" ]
permissive
# -*- encoding: utf-8 -*- from supriya.tools.ugentools.MultiOutUGen import MultiOutUGen class Pan2(MultiOutUGen): r'''A two channel equal power panner. :: >>> source = ugentools.WhiteNoise.ar() >>> pan_2 = ugentools.Pan2.ar( ... source=source, ... ) >>> pan_2 ...
JavaScript
UTF-8
4,565
3.0625
3
[ "MIT" ]
permissive
/** * Created by zmiter on 3/9/16. */ function Graph(id, leftX, rightX, bottomY, topY) { var vm = this; var MAGIC_HEIGHT_CONST = 0.9; vm.accuracy = 0.002; vm.plotNet = plotNet; vm.plotAxes = plotAxes; vm.setBorders = setBorders; vm.plot = plot; vm.canvas = document.getElementById(id)...
C++
UTF-8
3,655
2.6875
3
[]
no_license
/****************************************************************************** * SIENA: Simulation Investigation for Empirical Network Analysis * * Web: http://www.stats.ox.ac.uk/~snijders/siena/ * * File: CovariateDependentBehaviorEffect.cpp * * Description: This file contains the implementation of the * Cova...
Markdown
UTF-8
1,582
3.828125
4
[]
no_license
# 560. Subarray Sum Equals K ## 题 给定一个整数数组和一个整数 k,你需要找到该数组中和为 k 的连续的子数组的个数。 ## 解 ### 方法一: - 思路: - 暴力解法 - 时间复杂度: - o(n^2) - 空间复杂度: - o(1) - 结果: - 用时:超时 ``` class Solution { public: int subarraySum(vector<int>& nums, int k) { reverse(nums.begin(), nums.end()); int res...
Java
UTF-8
1,461
1.804688
2
[]
no_license
package p000X; import android.media.AudioAttributes; import android.media.AudioFocusRequest; import android.media.AudioManager; import androidx.media.AudioAttributesCompat; /* renamed from: X.DJ4 */ public final class DJ4 implements DJI { public AudioFocusRequest A00; public final AudioManager A01; publi...
TypeScript
UTF-8
5,459
2.84375
3
[ "Apache-2.0" ]
permissive
import { Keys, Types, KeyToType } from '@cdp/core-utils'; import { Subscription } from '@cdp/events'; import { Cancelable } from '@cdp/promise'; import { StorageData, StorageDataTypeList, StorageInputDataTypeList, IStorageOptions, IStorageDataOptions, IStorageDataReturnType, IStorageEventCallback, IStorage } from './in...
Java
UTF-8
3,868
1.945313
2
[]
no_license
package com.nst.yourname.model.callback; public class SeriesDBModel { private String backdrop; private String cast; private String categoryId; private String cover; private String director; private String genre; private int idAuto; private String last_modified; private String loginT...
Java
UTF-8
398
2.421875
2
[]
no_license
package com.zhao.KKPlayer.player; /** * 各种音乐格式的播放器接口 * @author Administrator * */ public interface MusicPlayer { /** * 播放 */ public void play(); public void stop(); public void pause(); public void resume(); /** * 关闭播放器读出来的流 */ public void close(); /** * 音乐快进或后退的方法 */ public void se...
Markdown
UTF-8
1,037
2.90625
3
[ "Unlicense" ]
permissive
## Table of Contents for Regex/[Character Class](https://www.hackerrank.com/domains/regex?filters%5Bsubdomains%5D%5B%5D=re-character-class) | # | File Name | Title | Difficulty | Max Score | | -- | ---------------------------------------------- | --------...
Python
UTF-8
2,202
3.265625
3
[]
no_license
from collections import deque import heapq # [G] [ ] [ ] [P] [ ] [ ] [G] def solution_dequeue(stalls, people): distances = deque((stalls,)) left, right = stalls, stalls while people: people -= 1 dist = distances.popleft() left = dist // 2 right = dist - left ...
Python
UTF-8
223
2.953125
3
[]
no_license
import os def valid_file(parser): def valid(arg): if arg and not os.path.exists(arg): parser.error('The file doesn\'t exist: {}'.format(arg)) else: return arg return valid
Java
UTF-8
2,290
2.171875
2
[]
no_license
package id.knt.restaurant.foodandbeverage.ui.recycle; import android.app.Activity; import android.content.Intent; import android.os.Bundle; import android.os.Handler; import android.view.View; import android.view.animation.Animation; import android.view.animation.AnimationUtils; import android.widget.Button; import an...
Python
UTF-8
5,702
2.765625
3
[]
no_license
from django.test import TestCase import datetime from ..models import AppUser, BoardMember, Board from django.db.utils import IntegrityError from django.contrib.auth import get_user_model user_model = get_user_model() class TestUserModel(TestCase): """ WIP """ pass class TestBoardModel(TestCase): ...
Markdown
UTF-8
2,487
2.65625
3
[ "MIT" ]
permissive
# Coinkite API Browser in [AngularJS](https://angularjs.org/) [Learn more about Coinkite's API here](https://docs.coinkite.com/) and visit the [Coinkite Main Site](https://coinkite.com/) to open your account today! ## Live Demo [coinkite.github.io/coinkite-angular](http://coinkite.github.io/coinkite-angular/) for a ...
Python
UTF-8
3,977
3.78125
4
[]
no_license
# https://www.cnblogs.com/mxh1099/p/8512552.html # #方法 #描述 # ------------------------------------------------------------------------------------------------- # D.clear() #移除D中的所有项 # D.copy() #返回D的副本 # D.fromkeys(seq[,val]) ...
Java
UTF-8
1,788
2.328125
2
[ "Apache-2.0" ]
permissive
package io.github.superfive666.duosdk.config; import lombok.Getter; import lombok.Setter; import lombok.extern.slf4j.Slf4j; import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.context.an...
JavaScript
UTF-8
3,020
2.625
3
[]
no_license
// cache names const staticCacheName = 'static-site-v1'; const dynamicCacheName = 'dynamic-site-v1'; //Cache assets array const assets = [ '/', '/index.html', '/static/js/main.chunk.js', '/static/js/bundle.js', '/static/js/0.chunk.js', '/Weather', '/Features', '/About', '/Business',...
Java
UTF-8
4,417
2.09375
2
[]
no_license
package pcpnru.projectModel; public class ProjectModel { // HD private String project_code, target, percen, year, datetime_response, freeze; private String project_name; // DT receive private String gcostcode, gcostname, budget, budget_now; // Project plan DT private String subjob_code, subjob_name, childsub...
Markdown
UTF-8
1,370
3
3
[ "MIT" ]
permissive
# go-hist simple go program to draw histograms Installation ----------- go get github.com/xigh/go-hist Documentation ----------- Usage: ./hist [options...] <file> -endian="little": endianess: [little, big] -gather="max": data gathering: [max, avg] -height=1000: image height -hmargin=10: horizonta...
C++
UTF-8
566
2.71875
3
[]
no_license
#include <iostream> #include <string.h> #include <fstream> #include <math.h> #include <vector> using namespace std; #define mod 1000000007 int easyLego(int n, int m) { vector<long long> F(m + 1, 1); long long a, b, c, d; for (int i = 1; i <= m; i ++) { a = F[i - 1]; b = (i - 2 < 0) ? 0 : F[i - 2]; c = (i - ...
Markdown
UTF-8
534
2.671875
3
[]
no_license
# Eloquent Javascript Solutions <p align="center"> <a href="https://eloquentjavascript.net/" style="display: block;"> <img align="center" width="320" height="445" src="https://i.imgur.com/fie9Rub.jpg" alt="Eloquent Javascript Book"/> </a> </p> ## About This repo contains several solution proposals for each ...
Java
UTF-8
718
2.0625
2
[]
no_license
/** * Pinganfu.com Inc. * Copyright (c) 2013-2013 All Rights Reserved. */ package com.pinganfu.bcm.common.model; import com.pinganfu.bcm.common.model.exception.BcmException; import com.pinganfu.bcm.service.facade.model.Cert; /** * 服务处理类. * @author zhaodongxu037 * */ public abstract class CatalogHandlerForMess...
C++
UTF-8
3,638
2.9375
3
[]
no_license
/* Carro Arduino com controle Bluetooth Código retirado do link abaixo: http://www.instructables.com/id/Arduino-Bluetooth-RC-Car-Android-Controlled/?ALLSTEPS Conclusão e adaptações por Usinainfo: http://www.usinainfo.com.br/ */ // Define os pinos de utilização do Driver L298. const int motorA1 = 4; ...
C++
UTF-8
2,028
2.90625
3
[ "MIT" ]
permissive
/* -*- c-basic-offset: 4 -*- */ #pragma once #include "Common.h" #include "ActionType.h" namespace BOSS { struct AbilityAction { ActionType type; // type of the ability TimeType frameCast; // the frame the ability was cast NumUnits targetID; ...
C++
UTF-8
660
2.515625
3
[]
no_license
#include<bits/stdc++.h> using namespace std; int tab[30][1000002],valor[30],N; int troco(int idx,int v){//solução recursiva TLE if(idx==N or v<0) return tab[idx][v]=0x3f3f3f3f; if(!v) return tab[idx][v]=0; if(tab[idx][v]>=0) return tab[idx][v]; int nao_escolhe = troco(idx+1,v); if(valor[idx]<=v){ int esco...
PHP
UTF-8
6,413
2.578125
3
[]
no_license
<?php class Validation { private $objForm; public $_errors = array(); public $_errorsMessages = array(); public $_message = array( "first_name" => "Please provide your first name.", "last_name" => "Please provide your last name.", "address...
Java
UTF-8
908
3.859375
4
[]
no_license
/** * A Class That Contains A Person Details * @author Alireza ZareZeynabadi * @version 1.0 * @since 2021.april.8 */ public class Person { private final String firstName; private final String lastName; /** * Constructor * @param firstName First Name of Person * @param lastName Last Nam...
C++
UTF-8
462
3.78125
4
[ "CC0-1.0" ]
permissive
#include <iostream> using namespace std; int main(void) { long long int n; // show instruction to user cout << "Enter the number:\t"; // scan user input cin >> n; // print "Number is odd" if it is odd else print "Number is even" // the 'bit-wise and (&)' operation returns 1 if the 1 is an...
Ruby
UTF-8
763
3.140625
3
[]
no_license
me = gets.chomp bool = true counter = 0 finish = "bye" finish.upcase if (me != finish || finish.upcase) while (bool) if /[[:lower:]]/.match(me) grandma = "HUH?! SPEAK UP, JOSHY!" puts grandma me = gets.chomp if (me == finish || me = finish.upcase) counter += 1 if (counter ...
JavaScript
UTF-8
395
2.8125
3
[]
no_license
//Función que se ejecuta una vez que se haya lanzado el evento de //que el documento se encuentra cargado, es decir, se encuentran todos los //elementos HTML presentes. document.addEventListener("DOMContentLoaded", function(e){ function logearse(){ if(localStorage.getItem("userName") == null){ win...
Java
UTF-8
2,870
3.59375
4
[]
no_license
package zty.practise.algo.leetcode800; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.HashSet; import java.util.List; import java.util.Set; /** * 解题分为两步 * * 第一步就是确定相等 * * 第二步就转化为将“相同”的字符串分到一组 * 其实最好的是使用空间工具比如map * 是否能转化出每个的一种基本格式 * 自定义hash? * * * 因为2...
Markdown
UTF-8
2,130
3.03125
3
[]
no_license
# CRM Portal Demo (Features) 1. Login Page: (with proper validations-- if you will not give user id and password in login page, it will give error). Default user id and password is : admin/admin 2. Dashboard: It displays information about CRM Portal purpose. It also displays the list of newly added customers. ...