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
2,127
3.0625
3
[]
no_license
#include <iostream> #include "InputManager.h" #include "SDL_events.h" InputManager* InputManager::instance = NULL; InputManager* InputManager::getInputManagerInstance(void) { if (instance == NULL) instance = new InputManager(); return instance; } bool InputManager::isKeyDown(const char* key) const { SDL_Scanco...
PHP
UTF-8
1,735
2.625
3
[ "MIT" ]
permissive
<?php namespace Retrowaver\Allegro\REST\Token\TokenManager; use Psr\Http\Message\ResponseInterface; use Retrowaver\Allegro\REST\Token\CredentialsInterface; use Retrowaver\Allegro\REST\Token\RefreshableTokenInterface; class RefreshableTokenManager extends BaseTokenManager implements RefreshableTokenManagerInterface { ...
PHP
UTF-8
2,330
2.609375
3
[ "MIT" ]
permissive
<?php //start by including the scripts required for this page include_once 'classes/class.Company.php'; include_once 'classes/class.dbc.php'; include_once 'includes/functions.php'; //contains our filter function and other functions //initialise the database variable to use in the application $db = new dbc(); $dbc = $...
Markdown
UTF-8
3,718
3.65625
4
[ "MIT" ]
permissive
--- layout: post title: "[LeetCode 60] Permutation Sequence" comments: true category: Leetcode --- ### Question [link](http://oj.leetcode.com/problems/permutation-sequence/) <div class="question-content"> <p></p><p>The set <code>[1,2,3,…,<i>n</i>]</code> contains a total of <i>n</i>! unique permutation...
Markdown
UTF-8
2,597
2.8125
3
[]
no_license
# Hello Vue.js 프로젝트 만들기 ## idnex.html 파일 생성 ``` <!DOCTYPE html> <html> <head> <title>Vue Sample</title> </head> <body> <div id="app"> {{ message }} </div> <script src="https://cdn.jsdelivr.net/npm/vue@2.5.2/dist/vue.js"></script> <script> new Vue({ el: "#app", ...
Markdown
UTF-8
7,331
2.671875
3
[ "GFDL-1.1-or-later", "MIT" ]
permissive
--- title: CoreCLR redirect_from: - /Moonlight2CoreCLR/ - /docs/advanced/coreclr/ --- Note: due to the circular nature of the definitions you'll need some prior knowledge of the CoreCLR security model **or** reading it twice to make sense out of this ;-) Security levels =============== The CoreCLR security model...
C++
UTF-8
296
3.046875
3
[]
no_license
#include <stdio.h> using namespace std; int main() { int s, v1, v2, t1, t2; scanf("%d %d %d %d %d", &s, &v1, &v2, &t1, &t2); int r1 = s * v1 + 2 * t1; int r2 = s * v2 + 2 * t2; if(r1 == r2) puts("Friendship"); if(r1 > r2) puts("Second"); if(r1 < r2) puts("First"); return 0; }
Python
UTF-8
19,998
2.734375
3
[ "MIT" ]
permissive
''' MIT License Copyright (c) 2021 Oz Mendelsohn Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish,...
C#
UTF-8
732
3.0625
3
[]
no_license
using System.ComponentModel; using System.ComponentModel.DataAnnotations; namespace BooksStore.Models { public class Author : INameable { public Author() : this("", null) { } public Author(string name) => Name = name; public Author(string name, string description) : t...
Java
UTF-8
6,872
2.515625
3
[]
no_license
package glorioso.pep.model.control; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import com.j256.ormlite.dao.Dao; import com.j256.ormlite.dao.DaoManager; import com.j256.ormlite.jdbc.JdbcConnectionSource; import com.j256.ormlite.stmt.QueryBuilder; import com.j256.ormlite.stmt.Where...
C#
UTF-8
1,072
2.75
3
[ "Apache-2.0" ]
permissive
using System; using System.Net; namespace Gov.TicketSearch.Auth { [Serializable] public class OAuthException : Exception { public HttpStatusCode StatusCode { get; private set; } public string Response { get; private set; } public System.Collections.Generic.IReadOnlyDictionary<str...
C++
UTF-8
5,531
3
3
[ "Apache-2.0" ]
permissive
#include "scopes.h" #include "symbols.h" namespace brutus { namespace internal { namespace syms { const float Scope::DefaultLoadFactor = 0.75f; Scope::Scope(int initialCapacity, float loadFactor, Arena* arena) : m_arena(arena), m_size(0), m_parent(nullptr) { int capacity = NextPow2(initialCapacity);...
Java
UTF-8
7,565
2.90625
3
[ "CC0-1.0" ]
permissive
package blockstorage; public class HDFSLayerTest { // private Utils utils = new Utils(); // @Test // public void WriteAndReadFromHDFSClusterDirectly1() { // HDFSLayer HDFSLayer = new HDFSLayer(); // SSD SSD = new SSD(HDFSLayer); // Cache Cache = new Cache(SSD); // // int numPages = 100; // int numBlocks = numPag...
Python
UTF-8
6,645
3.046875
3
[ "MIT" ]
permissive
# ./sedater/lib/filesystem.py # Author: Ulli Goschler <ulligoschler@gmail.com> # Modified: Thu, 10.12.2015 - 23:16:02 import os, sys import re from collections import namedtuple from sedater.lib.shared import Sourcefile from sedater.lib.shared import Orientation class Crawler(object): """ The Crawler opera...
PHP
UTF-8
1,551
2.6875
3
[]
no_license
<?php declare(strict_types = 1); $menu = [ [ 'title' => 'Home', 'link' => '', ], [ 'title' => 'Products', 'link' => 'products', 'submenu' => [ [ 'title' => 'Naujausi', 'link' => 'newest', ], [ ...
Java
UTF-8
2,793
2.390625
2
[]
no_license
package com.aptech.bookapp.controllers; import com.aptech.bookapp.models.User; import com.aptech.bookapp.services.IUserService; import com.aptech.bookapp.viewmodels.UserLoginViewModel; import com.aptech.bookapp.viewmodels.UserRegisterModel; import jakarta.validation.Valid; import lombok.RequiredArgsConstructor; import...
Markdown
UTF-8
922
2.921875
3
[]
no_license
# takeabeltof.jinja_filters.py Some custom filters to use in templates --- > #### iso_date_string(*value*): => str Returns a string formatted like a date as 'yyyy-mm-dd'. Value may be a datetime or a 'date like' string. --- > #### short_date_string(*value*): => str Returns a string formatted like a date in "'meri...
Markdown
UTF-8
17,559
3.046875
3
[]
no_license
# Greetings Heroes [View the live project here](https://bryansmullen.github.io/greetings-heroes/) ![Banner Image](wireframes/design-assets/../mockups/greetings-heroes-mockup.jpg) **Greetings Heroes** is an application which allows users to play a fun interactive role playing game. ## Contents - [Greetings Heroes](...
Java
UTF-8
395
3.296875
3
[]
no_license
package helloworldmine; import java.util.*; public class addition { public static void main(String[] args) { Scanner sc=new Scanner(System.in); System.out.println("please enter the number- 1 : "); int a = sc.nextInt(); System.out.println("please enter the number-2 : "); int b = sc.nextInt(); int sum = ...
C#
UTF-8
1,288
3.359375
3
[]
no_license
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace IdleHeroesCalculator.Data.Extensions { public static class EnumExtensions { public static string GetDescription(this Enum value) { var field = value.GetType().GetField( value.ToString() ...
Python
UTF-8
417
2.71875
3
[]
no_license
class Solution: def threeSum(self, nums: List[int]) -> List[List[int]]: n = len(nums) s = set() ans = set() for i in range(n): a = nums[i] for j in range(i+1, n): b = nums[j] c = 0-a-b if c in s: ...
C#
UTF-8
2,110
2.890625
3
[]
no_license
using Application.Requests; using AutoMapper; using FluentResults; using Infrastructure.Interfaces; using Infrastructure.Models; using MediatR; using System; using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; namespace Application.Handlers { /// <summary> ...
Java
UTF-8
5,786
1.960938
2
[]
no_license
package br.com.paybus.controle; import android.content.Context; import android.content.DialogInterface; import android.content.Intent; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.EditText; import android.widget.Spinner; im...
C#
UTF-8
5,698
3.0625
3
[]
no_license
using DungeonsOfDoom.Core; using DungeonsOfDoom.Core.Character; using DungeonsOfDoom.Core.Items; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Utils; namespace DungeonsOfDoom { class Game { Player player; Room[,] world...
C++
UTF-8
2,306
3.546875
4
[]
no_license
// // main.cpp // SmartString // // Created by Andrew Kireev on 20.02.2020. // Copyright © 2020 Andrew Kireev. All rights reserved. // #include <iostream> #include <vector> #include <string_view> #include <utility> class SmartStr { public: SmartStr() = default; SmartStr(const std::string& s){ std...
Java
UTF-8
912
1.96875
2
[]
no_license
package com.example.mvpzhenex.persenter; import com.example.mvpzhenex.ListBean; import com.example.mvpzhenex.Model.MainModel; import com.example.mvpzhenex.contrae.MainContrate; import com.example.mvpzhenex.util.CallBackList; import com.example.mvpzhenex.util.Url; public class MainPersenter extends BasePrensert implem...
Java
UTF-8
1,162
3.640625
4
[]
no_license
package io.abhishek.concurrency.factorythread; import java.util.ArrayList; import java.util.List; import java.util.concurrent.ThreadFactory; class Task implements Runnable { public void run() { try { System.out.println("Thread created " + Thread.currentThread().getName()); Thread.sleep(100); } ca...
C#
UTF-8
2,081
2.828125
3
[]
no_license
using System; using NetworkAdmin.ConsoleApp.Actions; using NetworkAdmin.ConsoleApp.Helpers; namespace NetworkAdmin.ConsoleApp.Managers { public class Ipv4ActionsManager: IActionManager { private readonly KeyboardInteraction _keyboardInteraction; public Ipv4ActionsManager(KeyboardInteraction k...
PHP
UTF-8
3,292
2.546875
3
[ "MIT" ]
permissive
<?php namespace App\Http\Controllers; use App\Task; use Illuminate\Http\Request; use App\Http\Controllers\Controller; use Illuminate\Support\Facades\Validator; use Illuminate\Support\Facades\DB; class TaskController extends Controller { /** * Create a new controller instance. * * @return void ...
Java
UTF-8
2,392
2.265625
2
[]
no_license
package com.example.chahlovkirill.exchangerate.Services; /** * Created by chahlov.kirill on 18/01/17. */ import com.example.chahlovkirill.exchangerate.Model.BankModel; import com.example.chahlovkirill.exchangerate.Model.CityModel; import com.example.chahlovkirill.exchangerate.Model.Gis2Model.Gis2Model; import com.g...
Java
UTF-8
546
2.65625
3
[]
no_license
package model; public class Timeslot{ private int startTime; private int endTime; private String day; public void setDay(String day){ this.day = day; } public String getDay(){ return this.day; } public void setStartTime(int startTime){ this.startTime = startT...
Python
UTF-8
336
3.390625
3
[]
no_license
import math def get_int(): return int(input()) def get_ints(): return [int(i) for i in input().split()] for t in range(0, get_int()): n = get_int() if n <= 1: print(0) continue m = n sq = int(math.sqrt(n)) if sq * sq == m: print(sq - 1 + sq - 1) elif (1 + sq) * sq >= n: print(sq + sq - 1) else: ...
Python
UTF-8
3,118
3.890625
4
[]
no_license
class Quicksort: def __init__(self, data): """ Init functie van de class""" self.data = data def start_recursive(self): """ Deze functie wordt aangeroepen om het recursive quicksort algoritme te gebruiken""" self.quicksortRecusrive(self.data, 0, len(self.data) - 1) def star...
TypeScript
UTF-8
1,549
2.9375
3
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
// Loaded from https://deno.land/x/axiod@0.20.0-0/helpers.ts export const methods = [ "get", "post", "put", "delete", "options", "head", "connect", "trace", "patch", ]; // /** // * Deep copy function for TypeScript. // * @param T Generic type of target/copied value. // * @param target Targ...
Java
UTF-8
4,654
1.710938
2
[]
no_license
package com.panda.mvp.ui.login; import android.app.ProgressDialog; import android.content.DialogInterface; import android.content.Intent; import android.os.Build; import android.os.Bundle; import android.support.v7.widget.Toolbar; import android.text.TextUtils; import android.util.Log; import android.view.Menu; import...
C++
UTF-8
1,273
2.5625
3
[]
no_license
#include <bits/stdc++.h> using namespace std; typedef vector<int> vi; typedef pair<int,int> ii; typedef vector<ii> vii; vector<vii> adjlist; int main() { ios_base::sync_with_stdio(false); freopen("i","r",stdin); freopen("o","w",stdout); int t; cin>>t; while(t--) { int v,m,x,y,t; ...
C#
UTF-8
726
2.71875
3
[]
no_license
// <copyright file="NullableDateTimeConverter.cs" company="Isaac Brown"> // Licensed under the MIT license. See LICENSE file in the project root for full license information. // </copyright> namespace SomeUser.Api.Mapping { using System; using AutoMapper; /// <summary> /// Converts DateTime? to string. ...
Java
UTF-8
5,259
1.945313
2
[]
no_license
package mineplex.core.gadget.gadgets; import java.util.ArrayList; import java.util.HashMap; import mineplex.core.common.util.C; import mineplex.core.common.util.F; import mineplex.core.common.util.UtilAction; import mineplex.core.common.util.UtilAlg; import mineplex.core.common.util.UtilEnt; import mineplex.core.commo...
Shell
UTF-8
548
3.703125
4
[]
no_license
#!/bin/bash if [ ! -n "$1" ];then echo "### Remover Error: Missing main (skill name) parameter!" exit 1 fi echo "INFO - Removing Skill $1" if cd /opt/mycroft/skills/$1 2>/dev/null then cd /opt/mycroft/skills && rm -rf $1 oname=$(echo $1 | awk -F"." '{print $1}') if (cd /opt/mycroft/skills/ui/skills/$oname)...
C++
UTF-8
5,186
3.421875
3
[]
no_license
#include "stdafx.h" #include "SimilarityCalculator.h" #include <Vector> SimilarityCalculator::SimilarityCalculator() // set values to 0 { intCountValue = 0; doubleCountValue = 0; floatCountValue = 0; charCountValue = 0; voidCountValue = 0; boolCountValue = 0; forCountValue = 0; ifCountValue = 0; elseCountVal...
C#
UTF-8
4,205
3.109375
3
[]
no_license
using System; using System.IO; using aspa.reversi.Models; namespace aspa.reversi { public class ConfigHandler { public static void DisplayHelp() { Console.WriteLine(); Console.WriteLine("Usage> reversi -par1 -par2 -l <filename>"); Console.WriteLine("-h\t\tSh...
Java
UTF-8
3,021
2.1875
2
[ "Apache-2.0" ]
permissive
/** * */ package com.thinkgem.jeesite.modules.wlpt.service.base; import java.util.ArrayList; import java.util.List; import java.util.Map; import org.jsoup.Jsoup; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.anno...
Markdown
UTF-8
870
2.625
3
[]
no_license
# Predict-ImageRotation-Angle ## Requirement please install the requirement.txt file before running the program pip install -r requirements.txt ## Test the results master_predict_rotation.py is the program which accepts two images and predict the roatation of the second imaged formed by rotating the first. pyt...
Python
UTF-8
3,575
2.59375
3
[]
no_license
import urllib.request as urllib2 from bs4 import BeautifulSoup import os from parser_attributes_JB import * from parse_title import parse_title from parse_cast import parse_cast from parse_director import parse_director from parse_writers import parse_writers from parse_numOfReviews import parse_numOfReviews from par...
C#
UTF-8
8,177
2.609375
3
[]
no_license
//Hecho por Ariel Arias using OfficeOpenXml; using System; using System.Collections.Generic; using System.Drawing; using System.IO; using System.Windows.Forms; using TCU_WFA.Models; namespace TCU_WFA { /// <summary> /// Clase encargada de la generación de los documentos excel /// </summary> public sta...
Markdown
UTF-8
6,013
3.75
4
[ "MIT" ]
permissive
枚举类型用于聚会被限定在一定范围内的场景,比如一周只能有七天,颜色限定为红绿蓝等 ## **简单的例子** 枚举使用 enum 关键字来定义 ``` enmu Days {Sun,Mon,Tue,Web,Thu,Fri,Sat} ``` 枚举成员会被同仁为从 0 开始递增的数字,同时也会对枚举值到枚举名进行反射映射 ``` enum Days {Sun, Mon, Tue, Wed, Thu, Fri, Sat}; console.log(Days["Sun"] === 0); // true console.log(Days["Mon"] === 1); // true console.log(Days["Tue"] ...
C++
UTF-8
950
3.484375
3
[]
no_license
#include<bits/stdc++.h> using namespace std; typedef struct node{ int data; node * next; } node; node * newNode(int data){ node * n = (node *)malloc(sizeof(node)); n->data = data; n->next = NULL; return n; } void sublist(node * first, node * second){ node * tmp = first; while(second->next != NULL && tmp->...
Markdown
UTF-8
9,923
2.5625
3
[ "MIT" ]
permissive
# Getting started with the CLI's esbuild-based build system <div class="alert is-important"> The esbuild-based ECMAScript module (ESM) application build system feature is available for [developer preview](/guide/releases#developer-preview). It's ready for you to try, but it might change before it is stable and is not...
Java
UTF-8
799
2.296875
2
[]
no_license
/** * */ package l2n.game.network.clientpackets; import l2n.game.model.actor.L2Player; /** * @author bloodshed (L2NextGen) * @date 15.12.2009 * @time 23:03:42 */ public class RequestModifyBookMarkSlot extends L2GameClientPacket { private static final String _C__51_REQUESTMODIFYBOOKMARKSLOT = "[C] d0:51:02 Req...
SQL
UTF-8
1,550
2.578125
3
[]
no_license
CREATE TABLE [TRN].[FinancingSchedule] ( [Id] VARCHAR (13) NOT NULL, [FinancingId] VARCHAR (10) NOT NULL, [InstallmentDate] DATETIME NOT NULL, [OldInstallmentDate] DATETIME NULL, [InstallmentNo] INT NO...
Java
UTF-8
872
2.921875
3
[]
no_license
package main.functions; import org.apache.commons.math3.stat.Frequency; /** * Created by gala on 20/03/17. */ public abstract class Harmonic implements Function { protected Function frequency; protected double start; protected double end; public Harmonic(Function freq, double start, double end) { ...
Markdown
UTF-8
7,200
2.703125
3
[]
no_license
File Uploader Widget Installation ------------ The preferred way to install this extension is through [composer](http://getcomposer.org/download/). Either run ``` composer require sergios/yii2-upload-file 'dev-master' ``` or add ``` "sergios/yii2-upload-file": "dev-master" ``` to the require section of your `com...
C++
UTF-8
323
2.90625
3
[]
no_license
#include "basic_classes.h" Response::Response() : cows(0), bulls(0) {} Response::Response(int cows, int bulls) : cows(cows), bulls(bulls) {} int Response::get_cows() const { return cows; } int Response::get_bulls() const { return bulls; } int Response::get_cows_and_bulls() const { return bulls + cows;...
Java
UTF-8
1,756
2.484375
2
[ "MIT" ]
permissive
package org.arp.model; import java.io.Serializable; import java.util.Date; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.PrePersist; import javax.persistence.Tabl...
Rust
UTF-8
645
3.53125
4
[ "Apache-2.0" ]
permissive
//! Change directory use crate::error::Error; use std::env; use std::path::PathBuf; /// Support for optionally changing the current directory prior to performing /// an operation #[derive(Clone, Debug)] pub struct Chdir { path: Option<PathBuf>, } impl Chdir { /// Create a new `Chdir` struct with an optional ...
Markdown
UTF-8
1,328
2.765625
3
[]
no_license
# Project 2: Chef's Table! Chef's Table! is an app that allows you to save your favorite recipes in one spot. ## User Story We wanted to create a place for people to be able to store all of their favorite recipes in one spot No more printing out a ton or recipes or scrolling through multiple websites to find that pe...
Python
UTF-8
1,898
3.6875
4
[]
no_license
import pygame pygame.init() # 초기화(반드시 필요) #화면크기 설정 screen_width = 480 # 가로 screen_height = 640 # 세로 screen = pygame.display.set_mode((screen_width, screen_height)) #화면 타이틀 설정 pygame.display.set_caption("hoonpig game") # 게임이름 #배경이미지 불러오기 background = pygame.image.load("./pygame_basic/background.png") ...
Markdown
UTF-8
15,512
2.71875
3
[ "MIT" ]
permissive
--- layout: post title: 面试专题之计算机网络 subtitle: Interview-Computer Network date: 2022-05-25 author: Zaki header-img: img/post-bg-re-vs-ng2.jpg catalog: true tags: - Interview --- # 计算机网络 ## 简述OSI七层协议 OSI七层协议包括:物理层,数据链路层,网络层,运输层,会话层,表示层, 应用层 ## 简述TCP/IP五层协议 TCP/IP五层协议包括:物理层,数据链路层,网络层,运输层,应用层 ## 物理层有什么作用 主要解决两...
JavaScript
UTF-8
7,595
2.53125
3
[]
no_license
// gallery routes - not user specific. These routes affect the entire gallery. // individual users should not be able to delete exhibits, walls, or the gallery. // patch to update comments in exhibit only 'use strict'; var config = require('../config'); var express = require('express'); var router = express.Router(...
Java
UTF-8
438
1.71875
2
[]
no_license
package org.irri.iric.chado; // Generated 05 26, 14 1:29:45 PM by Hibernate Tools 3.4.0.CR1 /** * FeatureUnion generated by hbm2java */ public class FeatureUnion implements java.io.Serializable { private FeatureUnionId id; public FeatureUnion() { } public FeatureUnion(FeatureUnionId id) { this.id = id; } ...
Java
UTF-8
3,459
2.484375
2
[]
no_license
package dmg.cells.nucleus; import java.io.PrintWriter; import java.util.Map; import org.dcache.util.Args; public class AbstractCellComponent implements CellInfoProvider, CellSetupProvider, CellMessageSender, CellLifeCycleAware { private CellEndpoint _endpoint; private CellAddressC...
Java
UTF-8
1,551
3.546875
4
[ "MIT" ]
permissive
package seedu.address.model.calorie; import static java.util.Objects.requireNonNull; import static seedu.address.commons.util.AppUtil.checkArgument; /** * Represents a Input food */ public class Food { public static final String MESSAGE_CONSTRAINTS = "Food can take any values, and it should not be ...
C#
UTF-8
1,480
2.59375
3
[]
no_license
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Drawing.Text; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace command_reviewer { public partial class FRMMain : Form { ...
PHP
UTF-8
368
2.53125
3
[]
no_license
<?php namespace Novel\Core\Tokens\FlowControl\IfStatement; use Novel\Core\IToken; use Novel\Core\Tokens\Scope\ICodeScopeToken; interface IIfConditionToken extends IToken { public function setBody(ICodeScopeToken $body): void; public function getBody(): ICodeScopeToken; public function getCondition(): IToken; pu...
Java
UTF-8
304
2.078125
2
[]
no_license
package com.bruce; import java.util.function.Consumer; /** * @Author: Bruce * @Date: 2019/5/27 19:36 * @Version 1.0 */ public interface Limit { int getLimit(); void notifyOnChange(Consumer<Integer> consumer); void onSample(long startTime, long rtt, int inflight, boolean didDrop); }
Markdown
UTF-8
3,999
3.109375
3
[]
no_license
# JoJo Programming Language It is a Turing complete programming language. ### In this language, it is implemented: * Variables (global or locale) * Functions (recursion is supported) * Input and output of variable values * Nested conditional statements but without else (it is proposed to write then a conditional op...
Java
UTF-8
2,170
2.40625
2
[]
no_license
package com.nazarmerza.quiz.domain; import static javax.persistence.GenerationType.IDENTITY; import javax.persistence.JoinColumn; import java.io.Serializable; import javax.persistence.CascadeType; import javax.persistence.Column; import javax.persistence.DiscriminatorColumn; import javax.persistence.Entity...
Java
UTF-8
362
1.695313
2
[]
no_license
package com.microstone.app.param; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import java.io.Serializable; @Data public class ReadInfoParam implements Serializable { private Long shareId; private Long weChatId; /** * 查看时长 */ @ApiModelProperty(value = "查看时长") pr...
Java
UTF-8
411
1.84375
2
[]
no_license
package com.bb.auth.config; import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; public class WebMvcConfig implements WebMvcConfigurer { @Override public void addViewControllers(ViewControllerRegistry regi...
JavaScript
UTF-8
397
2.6875
3
[]
no_license
const express = require("express"); // llamar la dependencia que instalamos const app = express(); // ejecutamos express app.get("*", (request, response) => { // get * -> va a recibir todas la peticiones response.send({ messange: "Chanchito Feliz" }); // response send -> para mandar }); app.listen(3000, ...
Python
UTF-8
1,252
3.09375
3
[]
no_license
from objects.RandomObject import RandomObject from objects.Direction import Direction #from objects import Room, RandomObject, Direction class Door(RandomObject): parameter_types = [] # Set our location for the description using from_room and the dict def describe(self,from_perspective): self.loca...
C++
UTF-8
9,403
2.953125
3
[ "MIT" ]
permissive
#include <iostream> #include <thread> #include <sstream> #include <random> #include <map> #include <deque> #include "messagingserver.hpp" #include "messagingclient.hpp" #ifndef _WIN32 #include <signal.h> #endif using std::cerr; using std::ostringstream; using std::string; using std::map; using std::make_unique; using...
Java
UTF-8
2,892
2.375
2
[]
no_license
package com.kentuckyspacetracker; import android.app.Activity; import android.support.v4.app.Fragment; import android.os.Bundle; import android.support.v4.app.FragmentActivity; import android.support.v4.app.FragmentManager; import android.support.v4.app.FragmentPagerAdapter; import android.support.v4.view.PagerAdapter...
Markdown
UTF-8
6,228
3.234375
3
[ "MIT" ]
permissive
## Application architecture with components Components are versatile tools to organize code and can be used in a variety of ways. ### Want to skip all this and just see the source? [JSBIn example](http://jsbin.com/luhipixipe/edit) **UPDATED:** This tutorial is of an older version here is a [working example in the la...
Markdown
UTF-8
1,270
2.96875
3
[]
no_license
### markdown 和 html - 标题 : `#`、 `h1~h6` - 列表 : 无序列表和有序列表 + 无序列表 : markdown : `- 或者 *`、html : `ul 和 li` + 有序列表 : markdown : `1. 2.`、html : `ol 和 li` - 图片和链接 : + markdown :`![图片的名称](图片链接绝对绝对路径)`、html : `<img src="绝对或者相对路径" alt=""/>` + markdown : `[文字](绝对路径)`、html : `<a href="" target="_blank" title=""/>` - 粗体和斜体 + ...
C++
UTF-8
3,235
3.046875
3
[]
no_license
#include <iostream> #include <unordered_map> #include <queue> #include <string> #include <vector> //structure to build the Huffman Tree struct tree { char data; long long int weight; tree* left, * right; tree(char data, long long int weight) :data(data), weight(weight), left(NULL), right(NULL) {} };...
Rust
UTF-8
18,554
2.703125
3
[ "Apache-2.0", "MIT" ]
permissive
//! This module defines [`MuResolutionHomomorphism`], which is a chain map from a //! [`FreeChainComplex`]. use std::ops::Range; use std::path::PathBuf; use std::sync::Arc; use crate::chain_complex::{ AugmentedChainComplex, BoundedChainComplex, ChainComplex, FreeChainComplex, }; use crate::save::SaveKind; use alge...
TypeScript
UTF-8
332
2.59375
3
[]
no_license
'use strict'; export{}; let lineCount: number = 4; let counter: number = 0; let pixel: string = "*"; let space: string = "" for (let i: number = 1; i < lineCount; i++) { space = space + " " } while (counter < lineCount) { console.log(space +pixel); pixel = pixel + "**" counter++; space = space.su...
Shell
UTF-8
4,348
3.546875
4
[ "MIT" ]
permissive
#!/bin/bash # Get the Real Username RUID=$(who | awk 'FNR == 1 {print $1}') # Translate Real Username to Real User ID RUSER_UID=$(id -u ${RUID}) # Set env for the Real User touch /home/${RUID}/.zshrc if [[ -f "/home/${RUID}/.zshrc" ]] ; then echo "source /usr/share/powerlevel9k/powerlevel9k.zsh-theme" >> "/home/...
Python
UTF-8
4,674
3.03125
3
[]
no_license
''' -*- coding: utf-8 -*- @Author : LiZhichao @Time : 2019/5/21 9:38 @Software: PyCharm @File : 16-Erode-Dilate.py ''' import cv2 as cv import numpy as np import matplotlib.pyplot as plt filename ='C:/Users/19845/Desktop/123.jpg' def Lookformin(subimg): (row,col)=subimg.shape min = 0 for i in range(...
Java
UTF-8
1,932
2.515625
3
[]
no_license
package com.example.czaro.inzynierka; import android.content.Intent; import android.support.design.widget.FloatingActionButton; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.Toast;...
Java
UTF-8
569
2.09375
2
[]
no_license
package com.lzw.android.weather.feature.home; import com.lzw.android.weather.di.scope.ActivityScoped; import com.lzw.android.weather.feature.home.HomePagePresenter; import dagger.Module; import dagger.Provides; import com.lzw.android.weather.feature.home.HomePageContract; @Module public class HomePageModule { ...
Python
UTF-8
438
3.8125
4
[]
no_license
n=eval(input("Enter the starting point N:\n")) m=eval(input("Enter the ending point M:\n")) print("The palindromic primes are:") for nmbr in range(n+1,m): if nmbr>1: for i in range(2,nmbr): if (nmbr%i)==0: break else: x=str(nmbr) if nmbr=...
Python
UTF-8
673
2.8125
3
[]
no_license
import os import sys from multiprocessing import Pipe,Process sortie,entre = Pipe() def Compil(arg : str): name = arg.replace(".c",".o") entre.send(name) entre.close() os.execlp('gcc','gcc','-c',arg,'-o',name) Processus = [] if __name__ == '__main__': if len(sys.argv) < 2: print("...
Markdown
UTF-8
4,366
2.890625
3
[ "MIT" ]
permissive
Title: Wyam 1.0 Lead: Over two years in the making. Published: 9/14/2017 Image: /images/fireworks.jpg Tags: - Wyam - static site generator - open source --- After a little over two years of development, I'm thrilled to announce that Wyam 1.0 is now released! [Wyam is a .NET static generator](https://wyam...
Markdown
UTF-8
1,924
3.203125
3
[ "MIT" ]
permissive
--- title: Calculating rotation transformation to align component with direction caption: Aligning Component With Rotation Transformation description: VBA example demonstrates hwo to calculate the rotation transformation to align the normal of the component's face with edge direction around the component's origin image...
Markdown
UTF-8
1,624
3.046875
3
[ "MIT" ]
permissive
# NRestful C# library to consume a Restful API from .NET **Usage:** Instantiate a client and pass the URL of the Resfult Api as a parameter and send a "GET" request. ```cs /*************** * WebApi URL: ***************/ const string Url = "http://localhost:3034/api/"; var client = new Client(Url); ...
Java
UTF-8
506
1.726563
2
[]
no_license
package com.yc.wowo.biz; import java.util.List; import com.yc.wowo.entities.AdminInfo; import com.yc.wowo.entities.GoodsType; import com.yc.wowo.entities.Shop; public interface IShopBiz { public List<GoodsType> find(); public List<AdminInfo> find(Integer rid ); public Integer add(String sname, String aname, S...
Java
UTF-8
435
2.96875
3
[]
no_license
package com.dragon.book.javacore.chapter5.objectAnalyzer; import java.util.ArrayList; /** * User: dengshenyan * Time: 2018-04-27 17:20 */ public class ObjectAnalyzerTest { public static void main(String[] args) { ArrayList<Integer> squares = new ArrayList<>(); for (int i = 1; i <= 5; i++) { ...
Python
UTF-8
3,719
2.671875
3
[ "BSD-2-Clause" ]
permissive
#################################################################################### # Note: 2nd. # Author: Gang-Cheng Huang (Jacky5112) # Date: Dec.9, 2020 # Lecture: Information Security Training and Education Center, C.C.I.T., N.D.U., Taiwan # Dataset. https://www.kaggle.com/c/dogs-vs-cats/data?select=train.zip ###...
Java
UTF-8
470
2.59375
3
[]
no_license
package engine.validation; import engine.Puzzle; /** * @author Nerijus */ public class PuzzleValidator { /** * Checks if puzzle contains valid questions * and that answers can fit into the puzzle. * Does not check if puzzle can be solved or not. * * @param puzzle puzzle to validate ...
C#
UTF-8
1,525
3.359375
3
[]
no_license
using NUnit.Framework; using System; using System.Collections.Generic; using System.Text; namespace LeetCode.Easy { class Factorial_Trailing_Zeroes { public int TrailingZeroes(int n) { if (n == 0) { return 0; } else { ...
Java
UTF-8
196
1.539063
2
[]
no_license
package ru.fizteh.fivt.orlovNikita.bind.test; public class ClassBadSerialisation { private ClassBadSerialisation pointer; public ClassBadSerialisation() { pointer = this; } }
Java
UTF-8
327
1.84375
2
[]
no_license
package com.movie.favorite.dao.impl; import com.movie.favorite.domain.Movie; import com.movie.favorite.dao.api.MovieDao; import org.springframework.stereotype.Repository; @Repository public class MovieDaoImpl extends BasicJpaDao<Movie> implements MovieDao { public MovieDaoImpl () { super (Movie.class); ...
Java
UTF-8
868
2.4375
2
[ "MIT" ]
permissive
package ch.itenengineering.env.client; import java.util.Hashtable; import javax.naming.Context; import javax.naming.InitialContext; import javax.naming.NamingException; import ch.itenengineering.env.ejb.EnvRemote; public class EnvClient { public static Context getInitialContext() throws NamingException { Hashta...
JavaScript
UTF-8
2,341
2.515625
3
[]
no_license
const nameMethods = [ {name: 'A1Z26'} ,{ name: 'ROT13' }, { name: 'Atbash' }, { name: 'Escítala' }, { name: 'Polybios' }, { name: 'Repetition' }, { name: 'Vigenère' }, { name: 'Cesar' }, { name: 'NumberBase' }, {name: 'Reverse'} ] const globalInputs = [ [],[],[],[{title: 'Rows'}, {title: 'Colum...
Ruby
UTF-8
4,016
2.921875
3
[ "MIT" ]
permissive
require "csv" module Geokit module Geocoders describe AirplaneGeocoder do it "should return a LatLng when given a valid city, state" do loc = Geokit::Geocoders::AirplaneGeocoder.geocode('Boston, MA') loc.class.should == LatLng loc.should be_valid end it "should return i...
Python
UTF-8
4,256
2.5625
3
[]
no_license
import random import os from PIL import Image from scipy.misc import imsave def select_images(num_test_images=50, path_imagesA='datasets/Day2Night/trainA/', path_imagesB='datasets/Day2Night/trainB/'): data_imagesA = os.listdir(path_imagesA) num_imagesA = len(data_imagesA) - 1 data_imagesB = os.listdir(p...
Python
UTF-8
162
2.890625
3
[]
no_license
""" Viết chương trình tạo mảng 3D 3*5*8 có mỗi phần tử là 0. """ arr = [[[0 for i in range(8)] for i in range(5)] for row in range(3)] print(arr)
Markdown
UTF-8
21,883
2.90625
3
[]
no_license
> [name=邱綜樹] 臭屁股 98下期中考 - 1. (25%)請問下列反應何者為本能的反應?何者為情結所引發的反應?請依據榮格的定義回答並略述其理由。 1. 我們最心愛的一本書遺失了,我們感到很懊惱。 2. 剛發生空難後,有些人不敢坐飛機。 3. 當我們走在路上,突然身旁有巨大的爆裂聲,我們因此嚇一跳。 4. 當有人拿槍對著我們時,我們會懼怕。 5. 當嬰兒吸奶時,我們突然將奶瓶拿走,嬰兒因此哭鬧。 2. (15%)我們提到,動物在REM睡眠階段,四肢肌肉會呈現鬆弛狀態。請解釋生理上為何需要在REM睡眠階段有這樣的反應。 3. (15%)由爬蟲類的腦部結構來看,爬蟲類是否會具有類...