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
Shell
UTF-8
3,583
3.609375
4
[ "MIT", "CC-BY-4.0" ]
permissive
# Copyright (c) 2016 Damien Tardy-Panis # # This file is subject to the terms and conditions defined in # file 'LICENSE', which is part of this source code package. # # Inputs validation functions ################################################################################ # Validate the position input # Globals:...
Markdown
UTF-8
1,504
2.625
3
[]
no_license
--- title: ०७५ सूक्तम् --- वि बाधस्व दृंहस्व वीडयस्वाधस्पदं शत्रवस्ते भवन्तु । सपत्नसाह ऋषभो जनाषाडुग्रश्चेत्ता पञ्च कृष्टीर्वि राज ।१। शिवं क्षेत्रमनमीवन्ते अस्तूत्तमे नाके अधि तिष्ठेहि । पुत्रान् भ्रातॄन् बहुलान् पश्यमानो विश्वे त्वा देवा इह धारयन्तु ।२। त्वष्टा रूपेण सविता सवेनाहर्मित्रेण वरुणेन रात्री । ...
PHP
UTF-8
4,232
2.578125
3
[ "Apache-2.0" ]
permissive
<?php require_once('../Connections/localhost.php'); ?> <?php if (!function_exists("GetSQLValueString")) { function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { if (PHP_VERSION < 6) { $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue; } ...
Go
UTF-8
6,041
2.859375
3
[ "Apache-2.0" ]
permissive
package GoMybatis import ( "fmt" "github.com/zhuxiujia/GoMybatis/utils" "testing" "time" ) type TestResult struct { Name string Amount1 float32 Amount2 float64 Age1 int Age2 int32 Age3 int64 Age4 uint Age5 uint8 Age6 uint16 Age7 uint32 Age8 uint64 Bool bool } //解码基本数据-in...
C++
UTF-8
2,925
2.9375
3
[]
no_license
#include "directoryviewer.h" #include <QDirModel> #include <QTreeView> #include <QHeaderView> #include <QInputDialog> #include <QMessageBox> DirectoryViewer::DirectoryViewer(QWidget *parent) : QDialog(parent) { model = new QDirModel; /*禁止模型的只读模式,表示模型可以将修改的数据写回文件系统*/ model->setReadOnly(false); /*设置...
JavaScript
UTF-8
13,078
2.71875
3
[ "MIT" ]
permissive
/* * Kalender Masehi/Hijriah * * Designed by ZulNs, @Gorontalo, Indonesia, 30 April 2017 */ function Calendar(isHijriMode, firstDayOfWeek, year, month) { if (typeof HijriDate === 'undefined') throw new Error('Required HijriDate() class!'); isHijriMode = !!isHijriMode; firstDayOfWeek = (firstDayOfWee...
Java
UTF-8
9,428
3.546875
4
[]
no_license
package Assignment1; /** * Main class - game that has player as the Jedi with his forces fighting agaist Sithlord * @author Pongsathorn Cherngchaosil 012124071 */ import java.util.Random; import java.util.Scanner; public class gameMain { public static void main( String args[]){ //Initialize variable for h...
JavaScript
UTF-8
39,442
2.78125
3
[]
no_license
window.addEventListener("load", setup, false); /* AJOUTER UNE ANNEE - mettre à jour le fichier index.csv - generer la texture et la place dans data/years/ */ var conteneur = "carte"; // id de la balise qui doit contenir la carte var tailleCartePourTexture = 520; // largeur et h...
C++
UTF-8
3,090
2.5625
3
[]
no_license
#ifndef _X86EMU_X86EMUINCREMENTDECREMENTREGISTERS_H #define _X86EMU_X86EMUINCREMENTDECREMENTREGISTERS_H #include <x86emu/X86EmulatorEnvironment.h> #include <x86emu/X86EmulatorInstructionDecoder.h> #include <x86emu/x86EmulatorDebug.h> #include <x86emu/instructions/x86primitiveInstructions.h> namespace X86Emu { // ...
Markdown
UTF-8
2,348
2.828125
3
[]
no_license
# Article Annexe 1 a) Membres de droit : Le représentant de l'Etat dans le département ou son représentant, président ; Le directeur du centre de formation en soins infirmiers. b) Représentants de l'organisme gestionnaire et personnalités compétentes : Le président du conseil d'administration de l'organisme gestio...
Markdown
UTF-8
21,010
2.75
3
[]
no_license
### 数据库配置mysql 准备工作 * 自行搭建mysql服务5.7 * 准备一个可以外部访问的账户,root也可以 * 创建数据库,不同于sqlite,数据选择mysql时 django不会帮你创建数据库,只会关联已有的数据库 创建数据库语句:在navicat执行,autotpsite为项目名称,方便统一记录 CREATE DATABASE `autotpsite` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; 安装pymysqlclient模块 pip...
Java
UTF-8
740
3.03125
3
[]
no_license
package qyh.leetcode.hard; /** * leetCode 295 * 中位数是有序列表中间的数。如果列表长度是偶数,中位数则是中间两个数的平均值。 * * 例如, * * [2,3,4]的中位数是 3 * * [2,3] 的中位数是 (2 + 3) / 2 = 2.5 * * 设计一个支持以下两种操作的数据结构: * * void addNum(int num) - 从数据流中添加一个整数到数据结构中。 * double findMedian() - 返回目前所有元素的中位数。 * * 来源:力扣(LeetCode) * 链接:https://leetcode-cn.com...
Java
UTF-8
1,961
2.796875
3
[ "Apache-2.0" ]
permissive
package codeu.chat.server; import java.util.concurrent.BlockingQueue; import java.lang.Runnable; import codeu.chat.common.Writeable; import codeu.chat.util.Serializers; import java.io.FileOutputStream; import java.io.FileInputStream; import java.io.File; import java.io.IOException; import java.io.FileNotFoundExcepti...
Ruby
UTF-8
66
3.265625
3
[]
no_license
puts (1..999).inject(0) {|s, i| (i%5==0 || i%3==0) ? s + i : s}
Java
UTF-8
18,049
2.109375
2
[]
no_license
package mg.studio.android.survey; import androidx.appcompat.app.AlertDialog; import androidx.appcompat.app.AppCompatActivity; import android.app.Activity; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.CheckBox; import android.wid...
Java
UTF-8
13,184
1.8125
2
[ "Apache-2.0" ]
permissive
/** */ package CIM15.IEC61970.Generation.Production; import CIM15.IEC61970.Core.Curve; import java.util.Date; import org.eclipse.emf.common.notify.NotificationChain; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.InternalEObject; /** * <!-- begin-user-doc --> * A representation of the model o...
Python
UTF-8
744
3.640625
4
[]
no_license
pre=[10,8,5,9,15,16] class TreeNode: def __init__(self,val): self.val=val self.left=self.right=None def pre_to_tree(pre): if not pre: return None root=TreeNode(pre[0]) st=[root] for i in range(1,len(pre)): tmp=None while st and pre[i]>st[-1].val: # st is increasin...
Java
UTF-8
3,679
2.671875
3
[]
no_license
package com.kdi.excore.states.menu; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.Rect; import com.kdi.excore.animations.ColorAnimation; import com.kdi.excore.entities.Enemy; import com.kdi.excore.game.Game; import com.kdi.excore.states.State; im...
Java
UTF-8
1,546
2.03125
2
[]
no_license
package com.joymain.ng.webapp.controller; import java.util.List; import com.joymain.ng.dao.SearchException; import com.joymain.ng.service.FoundationItemManager; import com.joymain.ng.model.FoundationItem; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotati...
Java
UTF-8
971
1.664063
2
[]
no_license
package android.support.p022v4.view; import android.os.Build.VERSION; import android.view.ViewGroup.MarginLayoutParams; /* renamed from: android.support.v4.view.h */ public final class C0976h { /* renamed from: a */ public static int m4119a(MarginLayoutParams marginLayoutParams) { if (VERSION.SDK_INT ...
Markdown
UTF-8
1,953
2.671875
3
[]
no_license
--- author: [Alfresco Documentation, Alfresco Documentation] audience: category: option: --- # Editing file and folder properties Edit the basic details of a folder or file to change its name, description, and tags. **Note:** If the selected folder or file has the *Classifiable* aspect applied, there will be an a...
C#
UTF-8
1,658
3.046875
3
[ "MIT", "CC-BY-4.0" ]
permissive
protected void AddUserToRoleButton_Click(object sender, EventArgs e) {      // Get the selected role and username      string selectedRoleName = RoleList.SelectedValue;      string userNameToAddToRole = UserNameToAddToRole.Text;      // Make sure that a value was entered      if (userNameToAddToRole.Trim().Leng...
C#
UTF-8
637
3.5
4
[]
no_license
using System; using System.Linq; namespace _08._Condense_Array_to_Number { class Program { static void Main(string[] args) { int[] nums = Console.ReadLine().Split().Select(int.Parse).ToArray(); while (nums.Length != 1) { int[] con...
Java
UTF-8
368
1.726563
2
[]
no_license
package com.ram.emailautomation.controller; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; @Controller @RequestMapping("error") public class ErrorController { @GetMapping("error") public St...
C++
UTF-8
256
2.65625
3
[]
no_license
#include <iostream> using namespace std; int main() { int x, y; cout <<"enter a numbers."<<endl; cout<<"first number :"; cin>>x; cout<<"second number :"; cin>>y; int i=x; while (i>=0) { i=y%i; y=x-i; } cout<<"hcf is : "<<i<<endl; return 0; }
Python
UTF-8
475
3.671875
4
[]
no_license
budget = float(input()) number_statists = int(input()) one_clothes = float(input()) decor = budget * 0.1; if number_statists > 150: money_clothes = (one_clothes * number_statists) * 0.9 else: money_clothes = one_clothes * number_statists leftMoney = budget - decor - money_clothes if leftMoney >=0: print...
Markdown
UTF-8
4,413
2.84375
3
[]
permissive
# Audio Source AM/FM/XM/DAB * Proposal: [SDL-0182](0182-audio-source-am-fm-xm.md) * Author: [Zhimin Yang](https://github.com/smartdevicelink/yang1070) * Status: **Accepted with Revisions** * Impacted Platforms: [iOS / Android / RPC / Core / HMI ] ## Introduction SDL remote control allows a mobile application to chan...
SQL
UTF-8
504
3
3
[]
no_license
select distinct a.osuser, a.username, a.machine, a.sid, a.serial#, 'alter system kill session ' || chr(39) || a.sid || ',' || a.serial# || chr(39) || ' immediate;' as comando_oracle, 'kill -9 ' || b.spid as c...
Python
UTF-8
136
3.09375
3
[]
no_license
import numpy as np print(np.linspace(1, 100, 10)) print(np.logspace(1, 2, 10)) print(np.logspace(np.log10(250), np.log10(500), 10))
Java
UTF-8
922
1.539063
2
[]
no_license
/*********************************************************************** * $Id: ReadVersionTaskTest.java,v1.0 2013-5-28 下午4:58:08 $ * * @author: Victor * * (c)Copyright 2011 Topvision All rights reserved. ***********************************************************************/ package com.topvision.framework.co...
JavaScript
GB18030
1,508
3.0625
3
[]
no_license
function validate( ) { var f=document.myform; //ûΪ if(f.userName.value=="") { alert("û"); f.userName.focus(); return false; } var e=document.myform.email.value; if (e.length==0) //ⳤǷΪ0ǷΪ { alert("ʼΪ!"); return false; } if (e.indexOf("@",0)==-1) /...
C++
UTF-8
11,279
2.859375
3
[]
no_license
// // Created by aless on 05/06/2018. // #include "Graph.h" #include <fstream> #define S 1 #define A 2 #define G 3 Graph::Graph() { _users_vector.resize(1); _relations.resize(1); _empty_rel.ptr=_temporary_rel.ptr= nullptr; _n_company=_n_group=_n_simple=0; } bool Graph::readFileRelatio...
JavaScript
UTF-8
1,565
3.078125
3
[ "MIT" ]
permissive
// C/M/n/c queue: // - a queue with constant entry rate, n servers // scheduler dequeues repeatedly until the serving queue is full, // then waits until the queue has space to start again: // while(!serving_queue_full) { // // } // Jobs return a promise // Bulk Jobs: // - take n promises and wait till all of them ...
Python
UTF-8
10,577
2.921875
3
[]
no_license
#!/usr/bin/env python # -*- coding: utf-8 -*- import pygame import random import math import sys from pygame.locals import * from OpenGL.GL import * from OpenGL.GLU import * def loadTexture(textura): textureSurface = pygame.image.load(textura) #carrega imagem da textura textureData = ...
Java
UTF-8
3,085
3.640625
4
[]
no_license
package enumerations; /** * The GameSprites enumeration is used as a way to easily reference the initial sprite properties for each entity. * The dimensions of the sprite are based on the associated animation's aspect ratio. * The dimensions of the sprite are used to scale the frame width and frame height to a more...
Markdown
UTF-8
10,690
2.546875
3
[ "MIT" ]
permissive
--- layout: post title: "코로나로 인해 재택근무를 하며 느낀점" date: 2020-03-01 18:23:00 tags: [diary] comments: true --- [코로나 19](https://search.naver.com/search.naver?sm=top_hty&fbm=1&ie=utf8&query=%EC%BD%94%EB%A1%9C%EB%82%98) 사태로 인해 갑작스럽게 이번주 화요일부터 다음주까지 전사 재택근무를 하게 되었다. 재택근무를 처음 해보기도 하고 갑작스럽게 결정되어 약간의 걱정 반, 기대 반으로 재택근무를 시작하게 되...
Python
UTF-8
2,253
2.6875
3
[]
no_license
import numpy as np import scipy as sp import matplotlib.pyplot as plt import time from scipy import ndimage #import time print "executing... takes about 5 mins.." start_time = time.time() leftim = sp.ndimage.imread('view3.png',flatten=True); rightim = sp.ndimage.imread('view1.png',flatten=True); plt.imshow...
Java
UTF-8
304
2.15625
2
[]
no_license
package com.flink.learn.window.aggregate; import lombok.Data; @Data public class StockPrice { private String symbol; private Double price; public StockPrice() { } public StockPrice(String symbol, Double price) { this.symbol = symbol; this.price = price; } }
Markdown
UTF-8
1,874
2.921875
3
[]
no_license
# Overview In this project you had to train two agents of tennis players, that try to keep the ball in the game as long as possible. The base for this project and algorithm was layed down by the Udacity team from the DRLND, which we were allowed to use and to adapt. I followed the tip of the team to use the DDPG algor...
Java
UTF-8
9,138
2.28125
2
[ "BSD-3-Clause" ]
permissive
package org.hybird.ui.hquery; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import java.awt.event.*; import javax.swing.JButton; import javax.swing.JComponent; import org.hybird.ui.AbstractTest; import org.hybird.ui.events.Composi...
Java
UTF-8
1,262
3.34375
3
[]
no_license
package ArrayProblem; import java.util.ArrayList; import java.util.List; public class Solution228 { public static void main(String[] args) { // TODO Auto-generated method stub int[] nums = {0}; int s = 0; int e = 1; String s1 = s+"->"+e; System.out.println(s1); ArraySolution228 result = ...
Java
UTF-8
1,161
2.640625
3
[ "Apache-2.0" ]
permissive
package net.osomahe.realapp.price.control; import java.util.Collection; import java.util.HashMap; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.atomic.AtomicLong; import javax.ejb.Singleton; import net.osomahe.realapp.price.entity.Price; /** * TODO write JavaDoc ...
C++
UTF-8
6,894
3.15625
3
[]
no_license
#include <iostream> #include <vector> #include <algorithm> using namespace std; class CPolynomial { private: vector<float> coe_table; static void set_coefficients(const bool was_x, unsigned &power, double &digit, CPolynomial &p, const int sign) { if (was_x && !power) { power = 1; ...
Shell
UTF-8
238
2.984375
3
[]
no_license
#!/bin/bash -x # trouble: сценарий для демонстрации распространенных видов ошибок number=1 if [ $number = 1 ]; then echo "Number is equal to 1." else echo "Number is not equal to 1." fi
Java
UTF-8
1,259
2.828125
3
[]
no_license
package nitka_2; import java.awt.Color; import java.awt.Graphics; import javax.swing.JApplet; public class Nitka_2 extends JApplet implements Runnable{ int x, y; @Override public void init(){ this.setSize(170, 550); x = 0; y = 550; Thread t = ne...
TypeScript
UTF-8
6,275
2.953125
3
[ "Apache-2.0" ]
permissive
// DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. // // Copyright 2016-2018 Pascal ECHEMANN. // // 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.apac...
JavaScript
UTF-8
8,069
3.25
3
[]
no_license
let _confirmDialog = null; let _promptDialog = null; /** * List-item objects. */ class ListItem { /** * Injects dependencies into list item class. * @param {function} confirmDialog * @param {function} promptDialog */ static init(confirmDialog, promptDialog) { _confirmDialog = confirmDialog; _prompt...
JavaScript
UTF-8
790
2.859375
3
[]
no_license
const hero = document.querySelector('.hero'); const text = hero.querySelector('h1'); const walk = 100; function shadow(e) { const {offsetWidth: width, offsetHeight: height} = hero; let {offsetX: x, offsetY: y} = e; if(this !== e.target) { x = x + e.target.offsetLeft; y = y + e.target.offse...
Java
UTF-8
209
2.125
2
[]
no_license
package com.deprommet.exception; public class ConflictException extends CustomException { public ConflictException(String message, String clientMessage) { super(message, clientMessage); } }
Python
UTF-8
723
2.6875
3
[]
no_license
#!/usr/bin/env python #Uncomment above line for executability under UNIX #This is for Windows, but will work under UNIX #Alex Grant spec = [] f = open( 'spec.spc' ) for line in f: if line[0] is not '#': spec.append( line ) for x in range( len( spec ) ): spec[x] = spec[x][:len( spec[x] ) -1] if __name__ == '__mai...
Java
UTF-8
2,445
2.671875
3
[]
no_license
package dao; import entity.TeacherEntity; import util.BaseDao; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; /** * Created by Ace on 2017/5/31. */ public class TeacherDao extends BaseDao{ public List<TeacherEntity> getList(TeacherEntity search){ ...
Java
UTF-8
12,961
2.21875
2
[]
no_license
package com.bianlaoshi.new1; import android.content.Context; import android.os.Bundle; import android.os.Handler; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.Ima...
Markdown
UTF-8
1,330
3.171875
3
[]
no_license
# Compare reference images to generated images. ## Note the tables's non-white background color - check for transparent images. <table style="background-color:#E6E6FA; border: 1px solid black;"> <tr> <th>Reference Plots</th> <th>Generated Plots</th> </tr> <tr> <td style="background-color:#E6E6FA; border: 1px solid b...
Python
UTF-8
220
3.421875
3
[]
no_license
#!/usr/bin/python #Read fucntion which reads by character size #f1=open("input.txt","r") #str=f1.read() #str=f1.read(30) #print "Read string is ",str for line in reversed(list(open("input.txt"))): print(line.rstrip())
Java
UTF-8
5,685
2.09375
2
[]
no_license
package org.netbeans.modules.groovy.editor.api.completion; import java.util.ArrayList; import java.util.EnumSet; import java.util.List; import java.util.Set; import javax.lang.model.element.TypeElement; import org.netbeans.api.java.source.ClassIndex; import org.netbeans.api.java.source.ClasspathInfo; import org.netbea...
Markdown
UTF-8
635
2.59375
3
[ "MIT" ]
permissive
Much like its parent, [\<n-view\>](/components/n-view), basic routing information is required. ```html <n-view ...> <n-view-prompt path='<sub-path>' page-title='<route title>' visit='always|once|optional' when='<expression predicate>' src='<remote html with route sand children>' content-src=...
Shell
UTF-8
875
2.734375
3
[]
no_license
echo "DOMAIN_HOME=${DOMAIN_HOME}" sed -i -e "s|ADMIN_PASSWORD|$s|g" /weblogic/create-T24-domain.py sed -i -e "s|ADMIN_PASSWORD|$s|g" /weblogic/t24DomainEnv.sh . /weblogic/oracle/wlserver/server/bin/setWLSEnv.sh # Create T24 domain wlst.sh -skipWLSModuleScanning /weblogic/create-T24-domain.py mkdir -p ${DOMAIN_HOME}/...
PHP
UTF-8
4,939
2.515625
3
[]
no_license
<?php declare(strict_types=1); namespace TMV\OpenIdClientModule\Client; use Interop\Container\ContainerInterface; use Interop\Container\Exception\ContainerException; use Jose\Component\Core\JWKSet; use TMV\OpenIdClient\AuthMethod\AuthMethodFactory; use TMV\OpenIdClient\AuthMethod\AuthMethodFactoryInterface; use TMV\...
Python
UTF-8
132
3.453125
3
[]
no_license
file = open("numbers.txt","r") number = file.readline() while number != "": print(number, end="") number = file.readline()
Markdown
UTF-8
676
2.796875
3
[ "MIT" ]
permissive
# Password Generator A tool to provide the user a way to have a password generated for them by following the prompts. The user can instruct the tool to include special characters in the password. ![ScreenShot](./Password-Generator.JPG) ## URL of Deployed Application https://designurhappy.github.io/Password-Generator...
Java
UTF-8
434
1.828125
2
[]
no_license
package eflowing.example.cloud.service.redis; import org.springframework.boot.SpringApplication; import org.springframework.cache.annotation.EnableCaching; import org.springframework.cloud.client.SpringCloudApplication; @SpringCloudApplication @EnableCaching public class RedisDemoApplication { public s...
Shell
UTF-8
698
3.859375
4
[]
no_license
#!/bin/sh # ---- Global variables ---- input=/dev/input/event1 code_prefix="ABS" code="${code_prefix}_[XY]" val_regex=".*(${code_prefix}_\(.\)), value \([-]\?[0-9]\+\)" val_subst="\1=\2" # ---- Functions ---- send_axis() { # 1. Convert axis value ($1) from device specific units # 2. Send this axis value via...
Java
UTF-8
2,560
2.421875
2
[]
no_license
package com.shaoyuanhu.dao.redis.impl; import com.shaoyuanhu.dao.redis.JedisClient; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import redis.clients.jedis.JedisCluster; import java.util.List; import java.util.Map; import java.util.Set; /** * @Descrip...
C
UTF-8
2,519
3.015625
3
[]
no_license
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <fcntl.h> #include <err.h> typedef struct info info; struct info{ char *coms[32]; char *in; char *out; }; char *arpath[] = {"/bin", "/usr/bin", "usr/local/bin"}; int **pipes; int numcoms; info data; void createpipes() { int i...
PHP
UTF-8
1,815
2.578125
3
[]
no_license
<? include ("inc/header.php"); ?> <? include ("inc/widget.php"); ?> <?php if ( empty($_SESSION['username'])) { include 'lib/redirect.php'; movePage(403,"login.php"); exit; }; include 'lib/mysql.php'; $sql = 'SELECT kundennummer, name, strasse, hausnummer, plz, ort, telefonnummer FROM kunde'; $stmt = $db_connection...
Markdown
UTF-8
1,159
3.0625
3
[ "Apache-2.0" ]
permissive
#记录在数据库设计以及操作过程中的某些设计思路和问题 *** >1.数据库连接类以及操作的封装 >>自己的打算是学习JFinal的设计思想,将所有的访问记录用一个Record类进行封装 也就是说一个Record相当于一条记录。这里的设计思想是由于ResultSet中记录和Model 层具有对应性,这样我可以在Record中持有Model,就可以产生与Model中每个字段 相对应的Map,用于存储一条记录。但是这里出现的问题是有些时候数据库表字段命名和 Model中对应字段命名可能是不同的,所以在建立映射关系的时候很麻烦。因此将这种设计思想搁置了。(这里利用反射的思想以及集合类建立对应关系) >>本次采用的方式:数据的查询以及更新...
Java
UTF-8
2,900
1.960938
2
[]
no_license
/* * @Title: TravelCore.java * @Package: com.t2mobile.logman.travel * @Project: Logman * @Version: 1.0.0 * @CopyRight: @2015 T2M-VAL */ package com.t2mobile.logman.travel; import java.io.UnsupportedEncodingException; import java.util.ArrayList; import java.util.List; import org.apache.htt...
Markdown
UTF-8
305
2.96875
3
[]
no_license
*The program calculates the hash of the file using the function **md5**, implemented in the library **openssl**.* *The complexity of the **O (n)** algorithm, because you need to analyze the entire file to get the result.* *The speed of the calculation depends on the size of the transferred file.*
PHP
UTF-8
1,208
2.65625
3
[ "Unlicense" ]
permissive
<?php namespace app\common; class OrderStatus extends \Prefab { const INITIAL = 0; const PREPARING = 1; const PREPARED = 2; const ALLOCATED = 3; const UPPER = 4; const SOLE = 5; const FINISH = 6; const CANCEL = 7; const WAITING = 8; function get() { $class = new \R...
Python
UTF-8
291
3.78125
4
[]
no_license
# Дан список чисел. Выведите все элементы списка, которые больше предыдущего # элемента.(input:1, 5, 2, 4, 3 output: 5, 4) a = input().split() for i in range(1, len(a)): if int(a[i])>int(a[i-1]): print(a[i])
Python
UTF-8
5,306
2.8125
3
[]
no_license
import subprocess import json import re from datetime import datetime from datetime import timedelta ''' PDF parser tool. https://github.com/pdfminer/pdfminer.six pip3 install pdfminer.six ''' #from tool import pdf2txt # from pdfminer.six class NKUST_Calendar: def __init__(self,file,term_year): self.r...
Java
UTF-8
2,149
2.859375
3
[]
no_license
import java.awt.Dimension; import java.awt.Graphics; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import javax.imageio.ImageIO; import javax.swing.JFrame; import javax.swing.JPanel; import org.imgscalr.Scalr; public class MaloWFrame { public class Panel extends JPanel {...
Markdown
UTF-8
9,927
2.5625
3
[]
no_license
1. What do you know in SQL? 1. Tell me how you use SQL at your company? What are the queries you wrote? 1. Tell me how you used SQL at UH Energy? 1. Why can't you use Excel instead of SQL? Is there a difference? 1. What is the difference between DELETE and TRUNCATE statements? 2. What are the different subsets of SQL?...
PHP
UTF-8
1,918
2.515625
3
[]
no_license
<?php /* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ /** * Description of Invoice * * @author DABBY(3pleMinds) */ require_once 'Connection.php'; require_once '../core/Core.php'...
Python
UTF-8
644
3.890625
4
[]
no_license
import random import sys randnumber=random.randint(1,10) #print(randnumber) print('What is your name') name=input() print('Hi',name,'Welcome to my guessing game. I am thinking of a number between 1 to 10. Take a guess') for i in range (0,5): number=int(input()) if number == randnumber: print('Good...
C++
UTF-8
2,095
3
3
[]
no_license
// g++ -std=c++11 solucionador.cpp -o solucionador #include "tabuleiro.hpp" #include <iostream> #include <cassert> Tabuleiro jogo; bool validarEDefinir(unsigned short valor, unsigned short i, unsigned short j) { jogo.setValorQuadrado(valor, i, j); // força a cor if ( jogo.regrasValidasPara(valor, i, j) ) retu...
C#
UTF-8
8,296
3.0625
3
[]
no_license
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Diagnostics; namespace Ropes { class Program { static void Main(string[] args) { Console.WriteLine(); Console.WriteLine("DELETE FROM MIDDLE"); string y = "0...
C++
UTF-8
801
2.796875
3
[]
no_license
// // Step.hpp // day01 // // Created by fangyukui on 2018/4/19. // Copyright © 2018年 fangyukui. All rights reserved. // #pragma once #include <iostream> using namespace std; class Step_Parent{ protected: int a; public: Step_Parent(int a){ this->a = a; } virtual void description(){...
Java
UTF-8
2,350
2.578125
3
[ "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
/* Copyright (c) 2020 W.T.J. Riezebos * * 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 law or agree...
C#
UTF-8
820
2.515625
3
[]
no_license
 using Sandbox; using Sandbox.UI; using Sandbox.UI.Construct; using System; using System.Linq; using System.Threading.Tasks; using System.Collections.Generic; using System.Reflection; namespace Sandbox.UI { public class Form : Panel { public object Bound; public Form() { AddClass( "form" ); } public ...
Python
UTF-8
3,117
3.453125
3
[]
no_license
# -*- coding: utf-8 -*- from __future__ import unicode_literals import sys # Step 1 - read input into data sctructure class Vessel: def __init__(self, vesselType, vesselWidth): self.vesselType = vesselType self.vesselWidth = vesselWidth filename = sys.argv[1] print("reading " + filename + "...") lineNumber ...
Shell
UTF-8
1,174
4.03125
4
[]
no_license
#!/bin/sh die () { echo >&2 "$@" exit 1 } # Validate arguments [ "$#" -ge 1 ] || die "Usage: $0 <path-to-srt>" [ -e "$1" ] || die "File $1 does not exist." # Find the associated MKV file and make sure it exists fullfile="$1" srtfile="${fullfile##*/}" mkvfile="${srtfile%.*}.mkv" tmpfile="${srtfile%.*}-subs.mkv...
Python
UTF-8
5,623
2.671875
3
[]
no_license
from fake_useragent import UserAgent from bs4 import BeautifulSoup as BS from dateutil.parser import parse import requests as rq import datetime import time import json import os, glob from copy import deepcopy CATEGORIES = ['정치', '경제', '사회', '생활', '세계', '과학'] CATEGORIES_ENGLISH = ['politics', 'economy', 'society', '...
Java
UTF-8
21,451
2.5625
3
[ "MIT" ]
permissive
// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov. // Jad home page: http://www.kpdus.com/jad.html // Decompiler options: packimports(3) annotate safe package android.support.v4.util; public final class CircularArray { public CircularArray() { this(8); // 0 0:aload_0 // 1 1:b...
PHP
UTF-8
2,002
3.140625
3
[ "MIT" ]
permissive
<?php namespace Core; use PDO; abstract class DB { /** * The PDO instance. * * @var \PDO */ private static $pdo; /** * The PDO data types. * * @var array */ protected static $dataTypes = [ 'boolean' => PDO::PARAM_BOOL, 'string' => PDO::PARAM_ST...
C#
UTF-8
404
2.75
3
[]
no_license
namespace ClassLibrary1 { public class Logger { public static string AssemblyGuid; public static void Init() { Assembly a = Assembly.GetCallingAssembly(); var attribute = (GuidAttribute)a.GetCustomAttributes(typeof(GuidAttribute), true...
JavaScript
UTF-8
13,141
2.6875
3
[ "BSD-3-Clause" ]
permissive
/** * PongUI * * @license http://opensource.org/licenses/bsd-license.php The BSD License */ PongUI.prototype = new PongObject(); function PongUI(){ this.ScoreBoards = {}; this.PlayerNames = {}; this.ReadyBoxes = {}; this.Buttons = {}; this.Lobby = null; this.Labels = {}; this.Paddles = {one: null, two: null...
TypeScript
UTF-8
13,050
2.515625
3
[]
no_license
/* eslint-disable @typescript-eslint/ban-ts-comment */ /** * Space Navigator Controls Component for A-Frame. * * Forked from: * https://developer.mozilla.org/en-US/docs/Web/API/Gamepad_API/Using_the_Gamepad_API * */ import { Vector3, Euler, Object3D } from "three"; const MAX_DELTA = 200, // ms ROTATION_EPS ...
Markdown
UTF-8
2,798
2.78125
3
[]
no_license
# TicketingService This is a ticketing service using tornado framework. Tornado version : 5.1.1 Torndb version : 0.3 Author : Mohammad Ali Poorafsahi # PreRequirements - python - mysql # Debian distribution command to install python and mysql: `$ apt install python mysql` # installation ## step 0:cloning the repo...
Python
UTF-8
1,107
3.109375
3
[]
no_license
import unittest from main import line_checksum_min_max, line_checksum_division, file_checksum class TestLineChecksumMinMax(unittest.TestCase): def test_easy(self): self.assertEqual(line_checksum_min_max('1234'), 3) def test_samples(self): self.assertEqual(line_checksum_min_max('5195'), 8) ...
Java
UTF-8
1,849
2.375
2
[]
no_license
package com.nongguanjia.doctorTian.bean; import android.os.Parcel; import android.os.Parcelable; public class AllEcho implements Parcelable{ private String TalkId; private String Photo; private String Name; private String Phone; private String Massage; private String Date; public String getTalkId() { retur...
C++
GB18030
380
2.734375
3
[]
no_license
#include <iostream> using namespace std; void foo(void); //LNq禡AΨܰϰܼƭ int x = 10;//ŧiܼ x int main(void) { cout<<"ܼ x = "<<x<<endl; foo(); cout<<"ܼ x = "<<x<<endl; return 0; } void foo(void) { int x = 20;//ŧiϰܼ x printf( "ϰܼ x = %d\n", x ); }
Markdown
UTF-8
4,294
2.8125
3
[ "Apache-2.0" ]
permissive
### Terraform Template to create a Single instance of FMCv, Ubuntu 18.04 LTS and Windows 10 all on the same Subnet. Simple Usage ----- This contains the bare minimum options to be configured for the VM to be provisioned. The entire code block provisions a Windows, a Linux VM and Cisco FMCv 7.0. An Ubuntu Server 18....
Go
UTF-8
1,851
2.546875
3
[ "Apache-2.0" ]
permissive
package mgo import ( "context" "github.com/yaziming/mgo/bson" "go.mongodb.org/mongo-driver/mongo" "go.mongodb.org/mongo-driver/mongo/options" "go.mongodb.org/mongo-driver/mongo/readpref" "time" ) type Pipe struct { pipeline interface{} query coll *Collection } func (p *Pipe) AllowDiskUse() *Pipe { p.allowD...
JavaScript
UTF-8
9,618
3.28125
3
[ "Apache-2.0" ]
permissive
/* Copyright 2015 Aleksandar Jankovic 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 law or agreed to in writing, so...
Java
UTF-8
229
1.5
2
[]
no_license
import com.sam.ui.Main; /*Run sql script in the file SQLscript in your database console to add required tables*/ public class OnlineretailDBProject3 { public static void main(String[] args) { new Main().start(); } }
C#
UTF-8
2,771
2.671875
3
[]
no_license
using System; using System.Collections.Generic; using System.IO; using System.Text; using BTCrawler.Common.Crawler; using BTCrawler.Common.FileHandler; namespace BTCrawler.Common { public class Controller { private readonly IAlreadyDownloadListFileLoader _alreadyDownloadListFileLoader; private...
Java
UTF-8
568
3.5625
4
[]
no_license
public class Main { public static void main(String[] args) { NumberGenerator oneToTen = new NumberGenerator(1,10); NumberGenerator elevenToTwenty = new NumberGenerator(11,20); Thread thread1 = new Thread(oneToTen); Thread thread2 = new Thread(elevenToTwenty); thread1.setPriority(Thread.MIN_PRIOR...
JavaScript
UTF-8
5,694
3.53125
4
[]
no_license
// validar login function validateEmail() { const emailInput = document.getElementById('login'); if (emailInput.value === 'tryber@teste.com') { return true; } return false; } // validar senha function validatePassword() { const passwordInput = document.getElementById('password'); if (passwordInput.va...
Java
UTF-8
1,572
3.1875
3
[]
no_license
package com.javarush.task.task13.task1326; /* Сортировка четных чисел из файла */ import java.io.*; import java.util.ArrayList; import java.util.Collections; public class Solution { public static void main(String[] args) throws IOException { // напишите тут ваш код // try { BufferedRe...