branch_name stringclasses 149
values | text stringlengths 23 89.3M | directory_id stringlengths 40 40 | languages listlengths 1 19 | num_files int64 1 11.8k | repo_language stringclasses 38
values | repo_name stringlengths 6 114 | revision_id stringlengths 40 40 | snapshot_id stringlengths 40 40 |
|---|---|---|---|---|---|---|---|---|
refs/heads/master | <file_sep>import matplotlib.pyplot as plt
import matplotlib as mpl
from matplotlib.dates import DateFormatter
from matplotlib.ticker import FormatStrFormatter
import pandas as pd
import numpy as np
from math import ceil, floor
from modules.ComsolModel import ComsolModel
from modules.MiscCalculations import TempDistSolv... | 896a4f562141ff2725a1d09489aa445d73960464 | [
"Python"
] | 21 | Python | reeksts/DynKap_data_processing | 8813236d553de51babdc3b37a77a7cf53f190729 | f8e50b492b84c74b6739a79ac0f9e7df5f24c527 |
refs/heads/master | <repo_name>marcushellberg/shopping-list<file_sep>/src/main/java/com/vaadin/tutorial/data/endpoint/ShoppingListEndpoint.java
package com.vaadin.tutorial.data.endpoint;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
import javax.annotation.PostConstruct;
import com.vaadin.fl... | eda71c854ca9d7a5ba649c912dd2067aea82ecf4 | [
"Markdown",
"Java",
"TypeScript"
] | 11 | Java | marcushellberg/shopping-list | 0c9d863a2d2df31cef8ba1694ba4ed32935f57f1 | 0f79ba61bccadd9d4b2b89894e9cc973f9da6422 |
refs/heads/master | <repo_name>LiboHuang1992/JavaSE<file_sep>/JavaSE_apps/src/com/bnu/DataStructures/CycleLinkedList.java
package com.bnu.DataStructures;
public class CycleLinkedList
{
private int length;
private class Node
{
private Node prev;
private Node next;
private int data;
}
}
<file_sep>/JavaSE_apps/src/com/bnu/bas... | 9621c2e70ae26145cf0971de5970f822f9f6c13e | [
"Java"
] | 2 | Java | LiboHuang1992/JavaSE | 05bd29a7ef1f7d58a4db58f016017ff0063e10d7 | 119d2da499c36a0283a01d43a7d4286bbcf306e6 |
refs/heads/master | <repo_name>hanyoupcho/react-native-chat<file_sep>/index.ios.js
import React, { Component } from 'react';
import {
AppRegistry,
} from 'react-native';
import App from './components/App';
export default class ChatNow extends Component {
render() {
return (
<App />
);
}
}
AppRegistry.registerCompone... | c944f687b1226a4c86b855e5e396fb5e66e91a3c | [
"JavaScript"
] | 2 | JavaScript | hanyoupcho/react-native-chat | 2bd8645c1a36f674b1cbeb2179ec399b6a2a505f | d3438848456fa1f0754a44d0092aea4e002ade26 |
refs/heads/master | <file_sep>/*
Copyright 2017 The Kubernetes Authors.
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... | 7a023898d56c1bcc5921f76e66d654df97fe9ddc | [
"Markdown",
"Go",
"Shell"
] | 9 | Go | maleck13/kubeopbot | b0068e9227f011361b880952b0e804a19e5c8494 | 317017fe904956bb3ab7fa1942ceb7dc4e63c038 |
refs/heads/master | <repo_name>kirisanth-g/watrhub<file_sep>/water.py
import json
def solve(elm):
limit = elm['truck']
n = len(elm['pipes'])
pipes = sorted(elm['pipes'], key=lambda p: p['litres'])
table = knapsack(limit, n, pipes)
i, cost = find_last_value(table[n])
route = trace(table, i, n, pipes)
res = {'P... | 06ab44fde265f2da0419c06de753239bfa03d147 | [
"Markdown",
"Python"
] | 3 | Python | kirisanth-g/watrhub | a770c08c96a48e924d45965a4e4d27af72e25db3 | 71c307bf6ced490aded3652b7617682511a7fa44 |
refs/heads/master | <file_sep>from rest_framework import serializers
from django.contrib.auth.models import User
from datetime import date
from .models import Flight, Booking, Profile
class FlightSerializer(serializers.ModelSerializer):
class Meta:
model = Flight
fields = ['destination', 'time', 'price', 'id']
class BookingSerial... | 011ebc7f3f0964dd6f41553245f3e08c22d6838e | [
"Python"
] | 1 | Python | bnmre81/REST_task_08 | 1b46a1ae411047cab00581c754e050f90f0194c7 | c5a4515d92e97b84b93d7014c279eb0d4896e6ff |
refs/heads/master | <repo_name>patrick-etcheverry/openclassdut-partie2<file_sep>/src/Migrations/Version20181105095333.php
<?php declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class ... | 9039f2a565ddfeac0735e2facf0d12bd0438a3e7 | [
"Markdown",
"PHP"
] | 9 | PHP | patrick-etcheverry/openclassdut-partie2 | 7853b131fecb64bb273fb2793bf98b2578224dc0 | db919b1cc90f21cb3474933bab6bde6abc85bf67 |
refs/heads/master | <repo_name>hexiaoah/hexiao<file_sep>/union-entrance/src/views/nav/navBar/createNavItems.js
import util from '../util'
import navList from './navData'
//menuIdList是权限的id集合
const { menuIdList = [] } = util.getCookie('entrance')
//判断有无权限显示
function hasPermission(id) {
return menuIdList.indexOf(id) !== -1
}
function getN... | c11378b01dad77900d9f9369eb6826ce93dc789f | [
"JavaScript",
"HTML",
"Markdown",
"Shell"
] | 471 | JavaScript | hexiaoah/hexiao | cdae42856566322c7a91dbd6a90b3fea8f3ff353 | 07cad4679a4bae6f6f41c3bd523f9d8ce2f5de2c |
refs/heads/main | <file_sep># Basic-Tuner
Basic Tuner implemented using Yin Algorithm
<file_sep>class Yin {
constructor(bSize, thresh) {
this.samplingRate = 48000;
this.bufferSize = bSize;
this.halfBufferSize = Math.floor(bSize / 2);
this.buffer = new Array(this.halfBufferSize).fill(0);
... | 0a9d703510a5e5ae46c47b13bf60a30f74ab95cf | [
"Markdown",
"JavaScript"
] | 2 | Markdown | Shubhranshu0103/Basic-Tuner | 44838fb7ab13f7376fc3bb5c5918063d73731b73 | 04004bb377ec82d675b377710ba9506a93cc690e |
refs/heads/master | <file_sep># compilador
Diagrama Sintático

EBNF
> PROGRAM = '<<?php , { COMMAND } , '?>>' ;
> BLOCK = '{', { COMMAND }, '}' ;
> COMMAND = ( λ | ASSIGNMENT | PRINT ), ';' | BLOCK | LOOP | CONDITIONAL ;
> ASSIGNMENT = IDENTIFIER, '=', RELEXPR, ';' ;
> PRINT = 'echo', RELEXPR, ';'... | e5301ee99200e49bb77386a3e97e83e520e70f80 | [
"Markdown",
"Python"
] | 2 | Markdown | franciol/compilador | 42d2907d2133d6997e7070bc1bae23c3c1edd0dc | 382c52cca6832effafa02dcff0d3adee496982c4 |
refs/heads/master | <repo_name>khuyennv/tokio_example<file_sep>/Cargo.toml
[package]
authors = ["khuyennv <<EMAIL>>"]
name = "tokio_fast"
version = "0.1.0"
[dependencies]
bytes = "0.4.8"
futures = "0.1.22"
tokio = "0.1.17"
socket2 = { version = "0.3.15", features = ["reuseport", "unix"] }
[profile.release]
codegen-units = 1
lto = true
o... | 40c66b796689352fb297d4177c24c1261c6d0fe6 | [
"TOML",
"Rust",
"Markdown"
] | 3 | TOML | khuyennv/tokio_example | 6617f038fe2a4bbe875ae6107d2af3f0783db7ff | 51b0eee7a01a452179c9625b4cb61a8cda7c959c |
refs/heads/master | <file_sep><?php
namespace Lexik\Bundle\MonologBrowserBundle\Model;
use Doctrine\DBAL\Driver\Connection;
use Doctrine\DBAL\Schema\Schema;
/**
* @author <NAME> <<EMAIL>>
*/
class SchemaBuilder
{
/**
* @var Connection $conn
*/
protected $conn;
/**
* @var Schema $schema
*/
protecte... | 031a6c3780aba4ec871050d251e15a446eb60464 | [
"PHP"
] | 1 | PHP | dinamic/LexikMonologBrowserBundle | a6e0db9c84276b961d2f91317c3463c44eb34bed | 3a9607ccdf1263d8b5b0dcb6b8e9257db361a377 |
refs/heads/master | <repo_name>meowsome/example-material-site<file_sep>/js/click.js
//Adapted from https://paulund.co.uk/smooth-scroll-to-internal-links-with-jquery
$('a[href^="#"].link').on('click', function () {
$("html, body").animate({
scrollTop: 0
});
setTimeout(function () {
var pageTitle = window.locatio... | 9add58b79dd1dd97ed56351dfca1649f5481f4a1 | [
"JavaScript",
"Markdown"
] | 3 | JavaScript | meowsome/example-material-site | bf3acea3215d7e12a9cb04aa532bb3125a49adec | 2253b4b542b254caf038ceb0d0707e31222d5542 |
refs/heads/master | <file_sep>// Variables
var password = "";
var passwordLength;
var lowerCaseConfirm;
var upperCaseConfirm;
var numericConfirm;
var specialCharConfirm;
var generateBtn = document.querySelector("#generate");
var copyBtn = document.querySelector("#copy");
// Arrays
var passwordArr = [];
var specialChar = ["~","!","@","... | 893e790f8c092103280be88d9af1f9c1d6d467ea | [
"JavaScript",
"Markdown"
] | 2 | JavaScript | mms211/Password-Generator | 03af72b5ca7cbedffced5c890dfcc8ebe960c4ee | 02eee85cfa99107603aa4ec3725ae1293886aef6 |
refs/heads/master | <file_sep>#!/bin/bash
session=$1
proj=$2
BASE="$HOME"
work () {
SLABS="$BASE/work/staples-lab"
proj=$1
tmux start-server
tmux new-session -d -s $session -n $proj
tmux send-keys -t $session:1 "cd $SLABS/$proj && git pull" C-m
tmux select-window -t $session:1
tmux attach-session -t $session
... | 3f789b9dfac035a2b80a92764fb3f7f3e95292af | [
"Shell"
] | 11 | Shell | oneness/rcfiles | 7b18ace2060f33410d6752988757a6de48dcdb06 | e523bf6b51de8c18b5d6ecbad78bb9be00eef773 |
refs/heads/master | <repo_name>chenjuyu/RadioButton<file_sep>/app/src/main/java/com/fuxi/myapplication/MainActivity.java
package com.fuxi.myapplication;
import androidx.appcompat.app.AppCompatActivity;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.graphics.Color;
import android... | e48c11d3b5e4912752383e5231178cc453000cd1 | [
"Java"
] | 1 | Java | chenjuyu/RadioButton | 1d094f4843f7ca81163564caed04452a8d3a36a3 | 1e30a38e8c2f8623fc1bf30b57e026a03bc03f57 |
refs/heads/master | <repo_name>treasure2013-groupwork/jenkins-test<file_sep>/tests/src/calc.php
<?php
function calc($arg){
return $arg;
}
<file_sep>/tests/test/CalcTest.php
<?php
require_once(dirname(__FILE__). '/../src/calc.php');
class CalcTest extends PHPUnit_Framework_TestCase
{
public function testcalc1(){
$this->assertEquals(... | f0e3aa84d67b8e58c0186b22fcce6b281b15248e | [
"PHP"
] | 2 | PHP | treasure2013-groupwork/jenkins-test | e2a92fe34a5a2ad4548d15293ab34c10e2d5d226 | 807afa832bba4981472e5f71f0c74cdcfc261eac |
refs/heads/master | <file_sep>#Aug. 29
# as.numeric(c("one", "two", "three"))
as.logical(c("TRUE", "FALSE", "NA", "true", "false"))
as.integer(c(1.2, -0.9999, -pi, exp(1)/exp(1)))
as.character(c(1, 2, 3))
as.numeric("1") + as.numeric("2")
#Attribute
x <- c(a = 1, b = 2.5, c = 3.7, d = 10)
x
names(x)
attributes(x)
attr(x, "units") = '... | 76d2a40ad7c2fe975504dc4d64c3ca4bf333f197 | [
"R"
] | 1 | R | Yue-You/Stat-243 | 2f5003b5bf926989ef4a1d0a4d90303ca5d84b2a | 398f6dc8710295364883fd09f451162114a0e912 |
refs/heads/master | <file_sep>package com.example.administrator.keepservicealive.activity;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import com.example.administrator.keepservicealive.R;
public class SingleActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanc... | 9616048a69b5352801c32ed47fc9d865adc00946 | [
"Java"
] | 2 | Java | lbhlc/KeepServiceAlive | cf643fe426ee458f78e21113f02dfdf8c86808e0 | 0c7f1bd32dba2dc8b5d0eb9a21c5bdf8cb03d846 |
refs/heads/master | <file_sep>import instruments.Drum;
import instruments.InstrumentType;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class DrumTest {
Drum drum;
@Before
public void before() {
drum = new Drum("Wood", "Blue", InstrumentType.PERCUSSION, 10, 20, "... | 489d76a91eaceb810c357b692583b73f8d7e998d | [
"Java"
] | 2 | Java | nimbus117/cc_w12_weekend_hw | 9beb76a2ee46172f69e3ba4ccb5502a06bcfb45c | 55a9b2a54cc5674e78d53e51d8ab790fb5491dea |
refs/heads/master | <repo_name>Deamon87/blsreader<file_sep>/src/com/wow/blsreader/BlsReaderMain.java
package com.wow.blsreader;
import com.peterfranza.LittleEndianDataInputStream;
import java.io.*;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.util.stream.Stream;
import jav... | 2444da5a2eca7d969ea55edcde1e7b0ebecf4c59 | [
"Java"
] | 1 | Java | Deamon87/blsreader | b78a9535f8462e7670ca018a94aaa80434a6f663 | 058212d5d2ac58b4be99eac042f7489f0e1142b3 |
refs/heads/master | <repo_name>raphaelthurnherr/mqttHostCom<file_sep>/hostCom/src/messagesManager.h
/*
* messagesManager.h
*
* Created on: 15 mars 2016
* Author: raph
*/
#ifndef MESSAGESMANAGER_H_
#define MESSAGESMANAGER_H_
extern char ClientID[50];
// Initialisation de la messagerie system (JSON<->MQTT)
int Ini... | 093032cb0c2c43cb02c6783aeef45bdedd1e208e | [
"C"
] | 2 | C | raphaelthurnherr/mqttHostCom | 2dda04c81ea00f7f6ca0d42674e4839c7f817ba7 | 95b3d83f4d142d60608ad31c92c606bd7a4c8132 |
refs/heads/master | <file_sep>import torch.nn as nn
import torch
import torchvision
from dv_code import cnn_autoencoder
print(dir(cnn_autoencoder))
<file_sep>import torch
import torch.nn as nn
import torchvision
from torch.utils.data import DataLoader
import os,sys
from tqdm.auto import tqdm
from PIL import Image, ImageFilter
import nump... | 62341d04366b01f5b7c2f850f25bffb9d79eb730 | [
"Markdown",
"Python"
] | 6 | Python | boykovdn/dv-code | e567bc270c05f12fd2660a256d3a6721faed3913 | 45c0633816703a4f439260154ff770fd8825a382 |
refs/heads/master | <file_sep>//small_mad_lib.cpp: This program asks the user for a number, country, animal and name and returns a string.
//Name: <NAME>
//Class Section: COSC-1436.900 Online
// Date: 09/26/2021
#include <iostream>
#include <iomanip>
#include <cmath>
#include <string>
using namespace std;
int main()
{
// Variables: ... | 4860001b099fafc1412d266f477cf10054103c87 | [
"C++"
] | 1 | C++ | MacLeanLuke/assignment_3b | 9fe94ea32c10a658646b640a641098092b8a8a3a | 74b3e8269df5ac764f62d8e38a8eb3b3b7e8e031 |
refs/heads/master | <file_sep># Number Guesser

# Tools used
* HTML/CSS
* JavaScript
* Bootstrap
# What I learned
* Bootstrap control
* Flow control
* DOM manipulation<file_sep>let randomNumber = Math.floor(Math.random() * 10) + 1;
let guessing = true;
let guesses = ... | dd70748ba43d44a173e22a8b78869c8e22977bfa | [
"Markdown",
"JavaScript"
] | 2 | Markdown | hibenca/Number-Guesser | 0a660c95b2857bca922242807ccc4f1a8a480f62 | fa469fea11e65d4bb229c07b977f65c60f960373 |
refs/heads/master | <file_sep># DjangoORM
`cd library`
run tests
```
python manage.py makemigrations
python manage.py test
```
```
coverage run manage.py test
coverage html
```
In order to execute actions correctly you need to copy file __classrom.yml into classroom.yml
<file_sep># .coveragerc to control coverage.py
[run]
source =
... | b52c02a54d95f9f3fa137837bd7dae707c3870e2 | [
"Markdown",
"Python",
"INI"
] | 3 | Markdown | waldemarantypov/sprint18_django_REST | 40dea1f6c72de60c03932679240d9a878afb4066 | f40a7171037b39f5faa5919a4d82982e799f6eca |
refs/heads/master | <repo_name>brandonIT/whackAMole<file_sep>/whackAMole/GameScene.swift
//
// GameScene.swift
// whackAMole
//
// Created by xcode on 2/19/20.
// Copyright © 2020 xcode. All rights reserved.
//
import SpriteKit
import GameplayKit
class GameScene: SKScene, SKPhysicsContactDelegate {
var goodMoleSprite:SKSpriteNo... | 5c6743801e184c23477e4458eef539d022de7cb4 | [
"Swift"
] | 1 | Swift | brandonIT/whackAMole | d6f8f4b2b33282261482d673a094379de8c68ba7 | 27e6ee90a7d745a6894fb32c584938324287e709 |
refs/heads/master | <file_sep>using System;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Extensions.Hosting;
namespace BackgroundServiceSample
{
public class TestHostedService : IHostedService
{
public Task StartAsync(CancellationToken cancellationToken)
{
Console.WriteLine("Te... | 1921be2cf253c66fcfc978ca56249623f2e4f317 | [
"C#"
] | 1 | C# | markvincze/BackgroundServiceSample | b63272bab6d3ef8a8e3a9514271dfa373ed08f4c | 3a5351c1b94307eeb886cecd78e8f02be9359b81 |
refs/heads/master | <repo_name>choi8488kr/web<file_sep>/8-28 MVC2/src/net/tis/mvc/GuestReplyInsert.java
package net.tis.mvc;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.ArrayList;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet... | 839c69574ff2ccf314d296289e76672ceafc7d1d | [
"Markdown",
"Java"
] | 5 | Java | choi8488kr/web | 85105385026eb50ae338064d9ce81c7b288e8a6b | 9079ebe075cee35d1880c594255b97e5b8300855 |
refs/heads/master | <file_sep>package com.jvra.pokemoncarddb;
import android.content.Context;
import android.content.Intent;
import android.graphics.drawable.Drawable;
import android.support.design.widget.NavigationView;
import android.support.v4.view.GravityCompat;
import android.support.v4.widget.DrawerLayout;
import android.support.v7... | 894629337b069e0335c1d87ca7b91c222711fcb9 | [
"Java"
] | 3 | Java | 666jeroen/PokeCardDB | f8d1c45ee12774d44cec9aa2a3b09d69a7639489 | 5de6dda46db0a538634bfd986bc0a046a13df1cf |
refs/heads/master | <repo_name>flosev/InputFormTestAngularWithoutGrunt<file_sep>/app/scripts/app.js
'use strict';
var app = angular.module('myApp', [
'myApp.controllers'
]);
app.config(['$routeProvider', function ($routeProvider) {
$routeProvider.
when('/', {
templateUrl: 'views/dashboard/chart.ht... | dec16f1ab7310aa4960f88e6c203d9949386e8d8 | [
"JavaScript"
] | 2 | JavaScript | flosev/InputFormTestAngularWithoutGrunt | 2498be5bec90145e5d2f32c2bb3c1cdcdc0acb07 | 9a9132d870e23161f8a13ad8edec11c957a94265 |
refs/heads/master | <repo_name>JeromeBu/05-twitter<file_sep>/server.js
var express = require("express");
var app = express();
const chalk = require("chalk");
const morgan = require("morgan");
var bodyParser = require("body-parser");
var multer = require("multer");
var cloudinary = require("cloudinary");
var cloudinaryStorage = require("mu... | c47aaac353f8970eda15c592fb19b4f77d360e38 | [
"JavaScript"
] | 1 | JavaScript | JeromeBu/05-twitter | f7b497b321bbc2ebfca6dd5226a3b26602fa97ba | a2a2417823dabecf2eb0c64960773cb8b1dc482e |
refs/heads/master | <repo_name>ONEPIECEWBY/keras_bert_english_sequence_labeling<file_sep>/data/get_crf_data.py
# -*- coding: utf-8 -*-
# @Time : 2020/12/30 15:05
# @Author : Jclian91
# @File : get_crf_data.py
# @Place : Yangpu, Shanghai
with open("conll2003.test", "r", encoding="utf-8") as f:
content = [_.strip() for _ in f.readlines(... | 3d75455e5315a84cf00743b1ee9d9e4fc872c133 | [
"Markdown",
"Python"
] | 3 | Python | ONEPIECEWBY/keras_bert_english_sequence_labeling | caf42e5f3b03733e108d0854450836c2cd35395f | e29dcba423e028b94554b8ba85a0acee3689d627 |
refs/heads/master | <repo_name>KakoDaSeZove/InformativnaAgencijaApp<file_sep>/app/src/main/java/com/example/androiddevelopment/informativnaagencijaapp/db/Komentari.java
package com.example.androiddevelopment.informativnaagencijaapp.db;
import com.j256.ormlite.dao.ForeignCollection;
import com.j256.ormlite.field.DatabaseField;
import com.... | 816c290dac7171e8d5a0b8b1ee3c88c51f13fc6e | [
"Java"
] | 3 | Java | KakoDaSeZove/InformativnaAgencijaApp | 5198fbf96dc415e7ec0f45458891504f428901ef | 3aa7ceb026bbc3ca00d46e16efba38b5587afedc |
refs/heads/master | <file_sep>package java_code;
public class BasicClass {
//Instance variable
String var1;
int cost = 0;
public BasicClass(String name_,int cost) {//constructor
var1 = name_;
this.cost = cost;//pass the instance of object
System.out.println("its working");
}
// basic function
int add(int a ,int b) {
if(a>... | 7d54b03f117b419424028b6a1171cedfa3fa5e93 | [
"Java"
] | 2 | Java | saurbkumar/java_codes | dfa0191076d0f475d661b0913a804fe4f733eadb | a3f69aacdc958f944a001328ccf6479a1705bfd1 |
refs/heads/master | <file_sep>import json
import unittest
from tests.mockito import mockito
from launchkey_twisted.twisted_api import JSONResponseBodyParser
class JSONResponseBodyParserTest(unittest.TestCase):
def tearDown(self):
mockito.unstub()
super(JSONResponseBodyParserTest, self).tearDown()
def setUp(self... | 62d69913aef6091b71f794ec8916a9ed99e773ee | [
"Markdown",
"Python",
"reStructuredText"
] | 13 | Python | LaunchKey/launchkey-python-twisted | 9257da50b14146a2a773a8562a415517b0b3bbbb | c7448b43ba7f71bc8514e9aa780e268a0ccd26ba |
refs/heads/master | <repo_name>lumyus/todo-android<file_sep>/app-singleactivity/src/main/java/net/xaethos/todofrontend/singleactivity/todoedit/EditPresenter.kt
package net.xaethos.todofrontend.singleactivity.todoedit
import android.support.v4.view.GravityCompat
import android.view.Gravity
import android.view.View
import android.widget.Ed... | 76dd77cd6d1c59166a41a8710776ec204a106562 | [
"Kotlin",
"Gradle"
] | 39 | Kotlin | lumyus/todo-android | 4ea9b84f1833735249f094fc8b7b013cbe1a3c82 | 23997994eabb66e3b1befd4fdc55d66c1ef8a7a1 |
refs/heads/master | <repo_name>rosynirvana/ZeroJudge<file_sep>/a414.cpp
#include <cstdio>
int main()
{
int n;
while(scanf("%d", &n) == 1 && n != 0){
int ary[40];
int pos = 0;
while(n > 0){
ary[pos++] = n % 2;
n /= 2;
}
int upper = pos-1;
pos = 0;
int sum;
if(ary[pos] == 0)
sum = 0;
else{
sum = 1;
++p... | d850e50d2cb97b85c524802201efb624889fe132 | [
"C++"
] | 71 | C++ | rosynirvana/ZeroJudge | c48e7daf99da3f8c5928d20b51510c4ddbdea161 | 347e8bd5b18adb20d8c39efa700056696c720f6c |
refs/heads/master | <file_sep>let dark = false;
$(document).on("click", "#btn_lampu", function () {
let img = $("#btn_lampu").find("img")[0];
if (dark) {
dark = false;
$("body").css("color", "black");
// $("h2").css("color", "white");
// $("h3").css("color", "white");
// $("h4").css("color", "white");
// $("h5"... | 1792fa4486be4dfcb99f0302c49a339f78613c06 | [
"JavaScript"
] | 2 | JavaScript | ihzaa/Si-David | 697d884226a65e0359013de7c652dd420ab2a4ce | 1ce60e3594b9386aac4d01267ea93ebf42683111 |
refs/heads/master | <repo_name>leostein1234/leostein1234<file_sep>/Rosilind prob/stronghold/Computing GC Content.py
def gc_Count (seq):
nucleotide= {"A": 0, "C": 0, "T": 0, "G": 0}
for nuc in seq:
if nuc in nucleotide:
nucleotide[nuc] += 1
percent_gc = 100* (nucleotide["G"] + nucleotide["C"]) / (nucleo... | 73ba080a0e26dbc2b08a99f05171bb0bdb9c23c2 | [
"Python"
] | 5 | Python | leostein1234/leostein1234 | 6b0cdcac1dc17fbf0b6a6b483847ef31e0a8dadc | 548a013dec07c3b1a2cc3e8dd67e4353eb15a9cb |
refs/heads/master | <file_sep>rootProject.name='Ourchat'
include ':app'
include ':login'
include ':chat'
include ':my'
include ':contacts'
include ':commond'
<file_sep>package com.lpm_wxl.chat.debug;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import com.lpm_wxl.chat.R;
public class Chat_Debug_MainActivi... | 9eebf60338bbc96f801db9251983289e2ff0ba03 | [
"Java",
"Gradle"
] | 4 | Gradle | laipanmeng/Ourchat | ed0e71f0a319a0e554566154f91805e8526a1cfa | 3010c88a56aa9e596c44990c067d0b45143bafe4 |
refs/heads/main | <repo_name>SwaXTech/CursoDjango<file_sep>/platzigram/views.py
from django.http import HttpResponse
from datetime import datetime
import json
def hello_world(request):
return HttpResponse("Hello, world!")
def time(request):
now = datetime.now().strftime('%b %dth, %Y - %H:%M hs')
return HttpResponse("Que onda!. ... | f8f5b7412353b11d2ef25d1756f143911c96be46 | [
"Python",
"Text",
"Shell"
] | 6 | Python | SwaXTech/CursoDjango | 03056e710a09a8d2d2c29a3edc7caede92116793 | 4d47e9f6664d4f77a3525853e8a5bf3d1e584f4a |
refs/heads/master | <repo_name>joebadmus/serenity-js<file_sep>/packages/core/src/reporting/serenity_bdd_reporter.ts
import * as _ from 'lodash';
import * as path from 'path';
import StackTrace = require('stacktrace-js');
import { StackFrame } from 'stacktrace-js';
import { Md5 } from 'ts-md5/dist/md5';
import { serenity } from '../';
imp... | 92444801601d1615a35f626da790247933303bb8 | [
"TypeScript"
] | 1 | TypeScript | joebadmus/serenity-js | 53e35812cda942ab7156f56f55c7c731576c7629 | 0423fc3b8912fba040ebff0d8f2d9a0f1007f6b9 |
refs/heads/master | <repo_name>DarrelDent/P412-Assignment-2<file_sep>/corrgram_script.R
corrgram(tmsalary,
upper.panel = panel.conf,
lower.panel = panel.shade)<file_sep>/boxplot_carat_script.R
boxplot(tmsalary$carat,
notch=TRUE,
col=28,
horizontal=TRUE,
main="Carat",
ylim=c(0,2... | 1c57031111d410e91c0eae97b6067f2db9f0943c | [
"R"
] | 31 | R | DarrelDent/P412-Assignment-2 | 2e42783bc01887583099a67d32ee9b747f3c81b4 | 93f713c2f42d04014dff1194f619b3be8aad1627 |
refs/heads/master | <file_sep>import LY from 'lvyii-engine'
import {blockFunc} from './blocks'
LY.Cloud.define('cloudTest', function (request) {
let {text} = request.params
return text?text:'hello lvyii'
})
LY.Cloud.define('getInfo', blockFunc.getInfo)<file_sep>import Eos from 'eosjs'
const eos = Eos({httpEndpoint: process.env.HTTP... | abb2485b8b34b74079822856a01ca8a435df603a | [
"JavaScript"
] | 2 | JavaScript | eosmonitor/EOSMonitorCloud | bdb6d80224809898e9c2fbdc030f79efc45e1be6 | e82fe58546449b39b2d922b82d4b2d3bac106242 |
refs/heads/master | <file_sep>import cv2
import numpy as np
#from cv2 import ellipse as cvellipse
from find_staff import rectify
def pix(np_array):
return tuple(np.round(np_array).astype(int))
def fit_note(note_h):
canvas_h = 2 * note_h
canvas_w = 3 * note_h
p = 0.63
angle = 65
theta = angl... | 84f651cc3ef5cc63c2f781f1b1fcdfcd797118ed | [
"Markdown",
"Python"
] | 6 | Python | estebanuri/sheet_scan | cb63c18bb6eab83c61f5ca2944e83bb1c4d349e6 | e807fc0cc2c549b7a3fa1514520e6dfc5b7ff3a0 |
refs/heads/master | <file_sep>#!/usr/bin/env node
const expect = require('chai').expect
const CliTest = require('command-line-test')
/* global describe:true */
/* global it:true */
/* eslint no-undef: "error" */
describe('Environment variable test', () => {
it('should print error if no both variables are not set', async () => {
co... | 8b9830b01e68a1c51b7746f65c746a366828e183 | [
"JavaScript",
"Makefile"
] | 2 | JavaScript | hjarrell/jira-timelog | e9926b4541a45c4978d8e598fecf51b954f200fa | e61f78ad3294310c853543daef9cff096b1b1255 |
refs/heads/master | <file_sep># Android sensor bridge for ROS
Publish sensor data from your phone (connected via WiFi or USB) to ROS.
## Overview
[](http://www.youtube.com/watch?v=K4_FIi-hl-w)
A collection of python scripts that publish sensor data from your ... | b04e27d4dd36dffe3efff5f5ea3ab31dcdc73aa5 | [
"Markdown",
"Python"
] | 4 | Markdown | robbeofficial/android_sensor_bridge | 02d5cbe1eb96e9172ede88bed18b1785ae394b28 | 3f16250282ff2f98df6a94bc066e3ebc8fb939bb |
refs/heads/master | <repo_name>javiss/weather-app<file_sep>/playground/promisesss.js
let asyncAdd = (a, b) => {
return new Promise((resolve, reject) => {
setTimeout(() => {
if (typeof a === 'number' && typeof b === 'number') {
resolve(a + b);
} else {
reject('not numbers');
}
}, 300);
});
};
... | ae43f0eed536a99ff20cfdadaf6dd68db3ed29f5 | [
"JavaScript"
] | 3 | JavaScript | javiss/weather-app | 232208ccf983333346788fbfa829cbf401c2b74e | e7e4d6198554fa2cdf68a08dd30c73293e64fc68 |
refs/heads/master | <repo_name>dorantor/php-vast<file_sep>/src/Ad/InLine.php
<?php
namespace Sokil\Vast\Ad;
use Sokil\Vast\Creative\AbstractLinearCreative;
use Sokil\Vast\Creative\InLine\Linear;
class InLine extends AbstractAdNode
{
/**
* Set Ad title
*
* @param string $value
*
* @return \Sokil\Vast\Ad\InLi... | 68d0a783275c0ec1cadced9279ca14c7fd800875 | [
"PHP"
] | 3 | PHP | dorantor/php-vast | ef3b8215170461f40c003d063167f2942c54b798 | 6d4685a2ff2edbd5f5875a94d8f34944652102c1 |
refs/heads/master | <file_sep>[RemoteSSH]
Host = 1.2.3.4
User = user
RemotePort = 443
LocalPort = 2222
[RemoteWeb]
Host = my.c2.com
FileName = cmd.txt
[Local]
Upgrade = yes
DistUpgrade = no
SetupVNC = no
AdditionalPackages = tree jq
<file_sep>from setuptools import setup
setup(
name='ptb',
version='0.1.0',
packages=['ptb'],... | 65078347c1ec87af5e0281bb4c1fa0801b5403ae | [
"Markdown",
"Python",
"INI"
] | 9 | INI | davidhamann/ptb | 7c13014d0f9a0b399055b6005ce2d8c2590896b3 | f332f7bf425ff2bfc9b3e1e3f85aaf9e178d3eda |
refs/heads/main | <file_sep>import pandas as pd
import numpy as np
import streamlit as st
import requests
import yfinance as yf
import plotly.express as px
import plotly.graph_objects as go
import io
st.sidebar.title("Options")
option = st.sidebar.selectbox("Which Dashboard?", ("Chart", "Portfolio", "Crypto", "Total Portfolio Holdi... | c6bff8dbe02368e61d0e032d05cf90710fcfec8e | [
"Markdown",
"Python",
"Text"
] | 3 | Python | michih8/StockApp | 6275894c2797848e18a0d4bb40ef09be75f9304b | 93fb7564cf129fe82745a709c7d4c50b1d9dc3db |
refs/heads/master | <file_sep>package com.miracle.camel.service;
import org.apache.camel.Exchange;
import org.apache.camel.Message;
import com.miracle.itx.utility.ITXInvoker;
public class ITXService {
@SuppressWarnings("static-access")
public String process(Exchange exchange) {
Message msg = exchange.getIn();
String mapName = (S... | 3d2710544dceddb4d578fefa6d80234ba64e378d | [
"Java"
] | 1 | Java | csnmiraclesoft/Camel-API | a09c19b6ab84d6e521555e0e108981a8ba4ba4ab | 46272265bd52b7c1513400a6f429d1e2644ce6ae |
refs/heads/main | <repo_name>frodo10messi/ios-form<file_sep>/Sources/Views/ToggleInputCell/ToggleInputCell.swift
//
// ToggleInputCell.swift
// iOSForm
//
// Created by <NAME> on 30/03/2021.
//
import UIKit
protocol ToggleInputCellDelegate: AnyObject {
func cell(_ cell: ToggleInputCell, didChangeValue value: Bool)
}
final cla... | a02619d0e0fac9ab3f9676a6ce70c10f5ca4beb0 | [
"Swift",
"Markdown"
] | 35 | Swift | frodo10messi/ios-form | 52f82c7dc0a9333fb33e58f61ee453d15a8a9968 | 2ce98d1e1e03082acf6a2e2936de43965c3708e0 |
refs/heads/master | <repo_name>yashjainaj/restaurant-site-using-html-css-php<file_sep>/cart/datecheck.php
<?php
$dat = $_POST['date'];
date_default_timezone_set("Asia/Kolkata");
$d= date("Y-m-d");
$d2= strtotime($d);
$d1= strtotime($dat);
if($d1 < $d2 ){
function died(){
echo'<script type="text/javascript"> alert('date must... | f7a1962702f73231a9dcb22c53858775d57afb01 | [
"PHP"
] | 10 | PHP | yashjainaj/restaurant-site-using-html-css-php | 6f00fccc35aac2c422280574ff2c285fdd3a0c6d | a955c9e78d969ebb3eb9537c2b7dfcf4ff063f72 |
refs/heads/master | <file_sep>const express = require('express');
const app = express();
const mongoose = require("mongoose")
const bcrypt = require("bcrypt")
const jwt = require("jsonwebtoken")
// connect to mongo db with all this strange options
// so you do not get all these annyoing warnings on connecting
mongoose.connect('mongodb://... | 280c52f8e2d1b8e7297183c018ce8b6406250b5f | [
"JavaScript",
"Markdown"
] | 2 | JavaScript | mojvaf/Mongoose-Workshop2 | 4204f7ff6234cf8f261b8df1b07d7577ada6409d | 55accf4a26f13f65243881057e1b64b76e631e33 |
refs/heads/master | <file_sep>#!/bin/bash
VENV="venv"
if [[ ! -d "$VENV" ]]; then
python -m venv "$VENV"
"$VENV"/bin/python -m pip install -r requirements.txt
fi
"$VENV"/bin/python project-euler-offline.py
<file_sep># Project Euler Offline
This is a quick program I threw together before getting on a plane so I would be able to solve PE ... | 0d24a1df9dd44d2d97f25f328e554b18e81fb43a | [
"Markdown",
"Shell"
] | 2 | Shell | csu/project-euler-offline | 9a3c5d6c12f743ef44d12224e0ce8963430af4b8 | ccb4b1967a1b90e0c226905d1c58383cfbcc4d69 |
refs/heads/master | <file_sep>from flask import Flask, request, render_template
import json
import requests
import re
import omdb
import wikipedia
app = Flask(__name__)
app.debug = True
@app.route('/')
def hello_world():
return 'Hello World!'
#Route 1 / FORM that sends data to be used in next view function
@app.route('/form')
def... | aa0ea8512b6b30870158fdff2c42a682395ba7f2 | [
"Python"
] | 2 | Python | dbcolber/HW3 | dabf3e1707abf19fe3cf2d6da8ead21503fd846f | 0f46f7f3d0112d8abf05d0697b95221edc3d2955 |
refs/heads/main | <repo_name>hondaminori/sample_app<file_sep>/docker-compose.yml
version: "3.9"
services:
rails:
build: .
container_name: rails
command: ash -c "rm -f tmp/pids/server.pid && bundle exec rails s -p 3000 -b '0.0.0.0'"
volumes:
- .:/sample_app
ports:
- "3000:3000"
env_file:
- .env... | 668348fa980e7114691786833ed1ec054cb56f21 | [
"Markdown",
"Ruby",
"YAML",
"Dockerfile"
] | 4 | YAML | hondaminori/sample_app | 17538fcfea4718df7a1a38db681117d0e45bf8d7 | 1f081a42cfc0aa487776f03cc5a72666eed4ec4a |
refs/heads/master | <file_sep>'use strict';
var browserify = require('browserify'),
browserSync = require('browser-sync'),
buffer = require('vinyl-buffer'),
config = require('../config'),
gulp = require('gulp'),
gulpif = require('gulp-if'),
gutil = require('gulp-util'),
handleErrors = require('../util/handleEr... | 85a657df96b1fa281a156385bc5de04c7f7fc45a | [
"JavaScript"
] | 5 | JavaScript | genarinno/frontend-projects | a55b87600670c96a26374e6e365bdc3364510933 | ba7f6c72975ccb74dd87c144d542126ce46977ac |
refs/heads/main | <repo_name>maxMaksum/balijavasp<file_sep>/components/Card/CardContentServices.js
import CardImage from "./CardImage";
function CardContentServices({mockData2}) {
return (
<div className=" flex flex-col md:flex-row w-full rounded shadow-lg text-gray-50 overflow-hidden space-y-2 space-x-2">
... | 5a48b5202bdc559600f409415239ff089587f340 | [
"JavaScript"
] | 23 | JavaScript | maxMaksum/balijavasp | 4ce733ae9847881b80e595cb7bdb1a401a578df3 | 8a2397a99cb6a4dfb7f94060a96a4f3af0b11c27 |
refs/heads/master | <file_sep>import json
def get_config():
with open("config/config.json", encoding="utf-8") as config_file:
return json.load(config_file) or None
<file_sep>import os
import cloudinary as Cloud
from config.config_json import get_config
def config_cloudinary():
cloudinary_config = get_config()["cloudinary... | 3ea04cbbd680b8b1a54acb28c731d0c03dc2c4c2 | [
"Markdown",
"Python",
"Text"
] | 10 | Python | jessicaramsa/proyecto-final-sp-api | fbe1e270819fc076cfeefca54f40651fe9d6f6aa | 45d8a69d89ade7ef3d9b7311c251cff8c73fbd04 |
refs/heads/master | <repo_name>coiller/24Puzzle<file_sep>/main.py
import copy
import random
import time
class Node(object):
def __init__(self, data, depth):
Node.is_legal_data(data)
self.data = data
self.depth = depth
def __eq__(self, other):
return self.data == other.data and isinstance(other, ... | a2b7dbeb775ab0042b10f00c29930d0fae2d7169 | [
"Python"
] | 1 | Python | coiller/24Puzzle | 26dfbc989e271fa5aec6492f0f670eb5a7685962 | 49d57966612177448a53017005cc288203999741 |
refs/heads/master | <file_sep>package com.example.noteboi;
import androidx.appcompat.app.AlertDialog;
import androidx.appcompat.app.AppCompatActivity;
import androidx.recyclerview.widget.DividerItemDecoration;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import androidx.swiper... | 1e198ddcac911c5b55053fcb1e244c02d1d00240 | [
"Markdown",
"Java"
] | 4 | Java | AmiraliSajadi/NoteBoi | d24bfc930e749f8ccf51cce135b2624649d7939f | 2ac6363155d1bca255b427dbeea8475e5ab7cb7e |
refs/heads/master | <file_sep># student-and-skill
랜덤으로 학생의 능력치를 배정하여
지정스킬을 수행한뒤 학생들의 능력치를 다시 재 점검한다.
-------------------------------------------------------------
2학년 1학기 프로그래밍언어에서 'C++'을 배울때 받았던 텀프로젝트이다.
학생들의 공통적인 능력치? 함수를 상위클래스에서 지정하여주고
또 가상클래스를 이용하여 각 학생들마다 능력치가 조금씩 다르게, 스킬들이 조금씩 다르게 하였다.
스킬은 직접 지정해준것을 사용하는데, 만약 수행할 능력치가 되지않을경우 스킬... | f3f5a0d5edbf351504c7d51083919b3526603d25 | [
"Markdown",
"C++"
] | 2 | Markdown | Wise-eun/student-and-skill | d4da3aa49ebdae5f0049bea9c9bf0c946e1571d3 | ac7541692a1131158d50174d0020c7f66215f959 |
refs/heads/main | <repo_name>KisaShket/internship65<file_sep>/65-2internship/Entities/DataModels/Entry.swift
import Foundation
struct Entry : Codable {
var link : [Link]?
var gdOrganization : [GdOrganization]?
var gdEmail : [GdEmail]?
var gdPhoneNumber : [GdPhoneNumber]?
var id : String?
var fullName :... | f2db1ac57d9ba7b4964ce9805097ba118a0bf94f | [
"Swift"
] | 32 | Swift | KisaShket/internship65 | 149b8258ff700f2b0cdf100aca7e97c2c00dd81a | 73a03fab1d08f462096c8e3b7f8660cfb6f9acdd |
refs/heads/main | <file_sep>"use strict";
const init = document.getElementById('init');
const load = document.getElementById('load');
const carousel = document.createElement("main");
let carousel_fragment = document.createDocumentFragment();
carousel.classList.add("scroll-container");
load.addEventListener('change', read_file);
... | cf0cb6e10a90dce9b210193b0cb92a63574b1ba2 | [
"JavaScript"
] | 1 | JavaScript | arifd/flashcards | 8a4e665bea8b55bb7464c2b21d3fb04855114b73 | 11510ace16f38a5f874c1631e72ee87744a22e69 |
refs/heads/master | <file_sep>import logging.config
from logging import FileHandler, StreamHandler
import os.path
#LOGS Configuration
default_formatter = logging.Formatter(\
"%(asctime)s:%(levelname)s:%(message)s")
console_handler = StreamHandler()
console_handler.setFormatter(default_formatter)
error_handler = FileHandler("... | cee8e4174d22e5d03b1065a4a685e2161fbf1754 | [
"Markdown",
"Python"
] | 7 | Python | philipsales/airflow-couchbase-elasticsearch | f9bf06d88956d3e2322a7dfa6207becbdc1d1769 | 911850d6328077361252ab5fbc7738726334892e |
refs/heads/master | <repo_name>yusadogru/Challenges<file_sep>/Palindromes.playground/Contents.swift
// Challenge: Write code that will evaluate if all the elements in the list are palindromes using Swift
// e.g. racecar reveresed is still racecar
//
// Palindrome: a word or phrase that can be read the same way forwards and backwards
// Re... | 761ba00bd7e18d02743dd8aa2953395cdbf4620b | [
"Swift"
] | 2 | Swift | yusadogru/Challenges | 6cbc6deaee2498fda246f61e686819ba2aa31c0e | d67bf40aa0fac114a1c8ee6a80ba1c8be6bbbab0 |
refs/heads/master | <file_sep>CREATE TABLE nodes (
id integer primary key,
path integer[]
);
-- node1(root)
-- ->node2
-- | ->node5
-- | |
-- ->node3
-- | ->node6
-- | | ->node8
-- | | |
-- | ->node7
-- | ->node9
-- ... | a6d0336d4897f6141a5d408a211c914a1b14df16 | [
"Markdown",
"SQL",
"JavaScript"
] | 3 | SQL | SoutisV/RESTful_api_Docker | 9c19f81e695ad555495ab9a04ae52bb0fa48bed3 | 8d447ad436c119fd8ac2544921538206ce11c610 |
refs/heads/master | <repo_name>Barney117/AAL-Assistant<file_sep>/android relay/AALassistant/app/src/main/java/com/example/aal_assistant/locationCon.java
package com.example.aal_assistant;
public class locationCon {
static double latitude;
static double longitude;
static String address;
public locationCon() {
}
... | aa9522fd4b73463031a8cfc629100fcb260bf36c | [
"Markdown",
"Java"
] | 7 | Java | Barney117/AAL-Assistant | 9b34d57893a0060d66e65448d9a5cad15e3eb814 | c261130a2c5095d28e5406618e566dcd0417d138 |
refs/heads/master | <file_sep>package cn.liu.mobilesafe.activity;
import android.content.DialogInterface;
import android.content.Intent;
import android.net.Uri;
import android.os.Environment;
import android.os.Handler;
import android.os.Message;
import android.support.v7.app.AlertDialog;
import android.support.v7.app.AppCompatActivity;
i... | 97e63cb6aee97b071b9664b2a1584a70181b65bc | [
"Java"
] | 1 | Java | liuyuquan123/MobileSafe | e9195e0acc73bb920d2148bff1648f7e7540f868 | d4cfc619e7fbe1de7328a3b1e4faf75444f72023 |
refs/heads/master | <file_sep><?php
/**
* The header for our theme.
*
* This is the template that displays all of the <head> section and everything up until <div id="content">
*
* @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
*
* @package hdmk
*/
?><!DOCTYPE html>
<html <?php la... | 06069fc9cc98c6d5bb2f2c26d5b0a4006ba5cccf | [
"PHP"
] | 2 | PHP | daniilz/mediakit.designretailonline.com | 1b795e7bb24a8998e50282a93eb6146c48dd59e0 | ec8a8a6db07ebe95fdc8cb2d38110c2f563c836e |
refs/heads/main | <repo_name>dariav-sys/goit-js-hw-11-timer<file_sep>/js/task-1.js
class CountdownTimer {
constructor({ selector, targetDate }) {
this.selector = selector;
this.targetDate = targetDate;
this.refs = {
days: document.querySelector('[data-value = "days"]'),
hours: document.querySelector('[data-val... | dfd5ee29aa63a51c68bd9454244d573b0b136354 | [
"JavaScript",
"Markdown"
] | 2 | JavaScript | dariav-sys/goit-js-hw-11-timer | 68e62f2b15f2d5bcaf8bf0a444013e997146eec1 | 39ae2f0358829897172d32650fc5601cf1d734c1 |
refs/heads/master | <file_sep>class User < ActiveRecord::Base
has_many :trips_as_driver, class_name: 'Trip', foreign_key: 'driver_id'
has_many :gps_locations, class_name: 'GpsLocation', foreign_key: 'user_id'
#TODO:
# has_many :trips_as_follower,
end
<file_sep>Rails.application.routes.draw do
match 'api/s... | df1dc2f1dd32086062f6e94bfd9cbcfbd7ae8617 | [
"Ruby"
] | 10 | Ruby | alankrit/follow_crocodiles | 313b62f3d8dbee80ca562ab8b3ef34a4a6e3beba | b628f93752f619810fd44515ed3e8d298113269a |
refs/heads/master | <repo_name>Rachitahuja20/Ruby<file_sep>/Sentianalysis.rb
require 'rubygems'
require 'json'
require 'sentimental'
a=[]
from_file = ARGV.first
indata = open(from_file).read
#JSON Parser
json = JSON.parse(indata)
json["user_reviews"].each do |user_reviews|
a.push(user_reviews["review"]["review_text"])
end
analyzer ... | df6706514383da553ddcce48fc92bf6fbecdc630 | [
"Markdown",
"Ruby"
] | 6 | Ruby | Rachitahuja20/Ruby | c99d3010382288f14c8f189dade99b079c99fae7 | 7c70ef8eacb7188d88a0c287d4ec062a7072694b |
refs/heads/master | <repo_name>evargasguarniz/symfony<file_sep>/src/Distrito/CaseriosBundle/Entity/Galeria.php
<?php
namespace Distrito\CaseriosBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* Galeria
*
* @ORM\Table()
* @ORM\Entity
*/
class Galeria
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integ... | 9db6a2bbdbfe8fdc517a5f10d813b9aa080c8937 | [
"JavaScript",
"SQL",
"PHP"
] | 13 | PHP | evargasguarniz/symfony | 45ca266767f9cace8aeee64be7fa9a095d697f7d | 2538901b8eb9963c787f23f7b2eb04368429bf24 |
refs/heads/master | <repo_name>Kumahia-R/EECE.3220-Programs<file_sep>/EECE.3220 Programs/Prog3_stack_calc.cpp
#include <iostream>
#include <string>
#include <cctype>
#include "Node.h"
#include "Stack.h"
using namespace std;
int pemdas(char op) {
if (op == '*' || op == '/') {
return 2;
}
else {
return 1;
}
}
int operation(char ope... | ed2835b46a3d5cffbef453ac11a0cf3792b0bc0b | [
"C++"
] | 31 | C++ | Kumahia-R/EECE.3220-Programs | f205b8bb61a795c25a530800c68abfb375375735 | 873d4152db0f3dd115ad7c6c269a2af4b26e9873 |
refs/heads/master | <repo_name>anubhavashok/must_talk_cs_math<file_sep>/README.txt
Code from talk on Monday night;
EditDistance - EditDistance path problem + graph visualization (Doesn't work in IE);
ImageRectification - Painting problem (Requires opencv libs and python binding to run code);
Check out my startup: www.textedb.com;
And foll... | 7e0f05e474cd9dbe80c5207667ddce461e80d114 | [
"Python",
"Text"
] | 2 | Text | anubhavashok/must_talk_cs_math | 54f2f7d6121e52b7ec25e12e96db6c07414bd64a | b57e9fc9b6378ff6fa4fa98fa9ff85743e793d5a |
refs/heads/master | <file_sep>import { ADD, EDIT, REMOVE } from "../actions";
const initialState = {
todos: [],
count: 0
}
//reducer
export default (state = initialState, action) => {
switch (action.type) {
case ADD:
return Object.assign({}, state, state.todos.push(action.value, state.count), state.count... | c8ae9af2128bb851175df6630c57f97e08679876 | [
"JavaScript",
"Markdown"
] | 3 | JavaScript | Fioringo/CUNY2X-Todo-List | ce2a70de999dc212c27fd76387887917dfcdd6b4 | 66ea1d57625e189665afc0eab5a32232b03830a3 |
refs/heads/master | <repo_name>GabrielMorais2/api_atividade<file_sep>/utils.py
from models import Pessoas
#insere dados na tabela pessoa
def insere_pessoas():
pessoa = Pessoas(nome='selma', idade=47)
print(pessoa)
Pessoas.save(pessoa)
#realiza consulta na tabela Pessoas
def consulta_pessoas():
pessoa = Pessoas.query.al... | 6968bb4e93a64002d83722f9cb20671a612b440c | [
"Python"
] | 1 | Python | GabrielMorais2/api_atividade | ec6e04f1d44efc1ad29f95b9ce16a76e6038e4a6 | fee0afa56c771bfd415004da5cefb5626d9d55aa |
refs/heads/master | <repo_name>bonarl/Arduino-Flex-Tester<file_sep>/flex_tester.py
# -*- coding: utf-8 -*-
"""
Created on Tue Feb 14 11:44:17 2017
@author: bonar
"""
from port_finder import listSerialPorts
from Expander import EXPANDER
import serial
import time
import datetime
import socket
import sys
from flex_tools import *
#Flex-Ta... | 0a7bec0bc7d23bff5758357562cfc213cc0ddc7c | [
"Python"
] | 1 | Python | bonarl/Arduino-Flex-Tester | 719cc58be41e2d79c5745d8175319316db86d342 | 98d1d65b40314cd2cd78b2869d5131438891f4ea |
refs/heads/master | <repo_name>ed-khalid/SWE642<file_sep>/HW5/src/resources/db.properties
db.url=jdbc:oracle:thin:@apollo.vse.g<EMAIL>:1521/ITE10G.ITE.GMU.EDU
db.username=amuhamm3
db.password=<PASSWORD>
<file_sep>/HW4/web/scripts/main.js
//namespaces
var App = {};
var Cookies = {}
var SurveyMath = {};
var EventHandlers = {};
var Error = ... | 5f98ac8f105d660aeeb5c93e7f0ea11127224869 | [
"JavaScript",
"Java",
"INI"
] | 4 | INI | ed-khalid/SWE642 | 8292da733498f8bb7292ae98371488c509addc89 | db13cb74ef86e2e90345c3b5f3fdfcba9d3e2f2c |
refs/heads/master | <repo_name>iliescua/JoystickAPI<file_sep>/joystickAPI/joystick.h
/*
* <NAME>
* 4/1/19
* The .h file for the joystick
*/
#ifndef JOYSTICK_H_
#define JOYSTICK_H_
#include "alt_types.h"
#include <unistd.h>
#include "servoControl.h"
#include "sevenSegDisplay.h"
//The method that allows the servos to move based on joy... | 777e60093daa9862ef2f308775154a37a904c865 | [
"Markdown",
"C"
] | 8 | C | iliescua/JoystickAPI | 6b533afa1ba901c4984ed4d73f21c3aa45eb4851 | 8999a785067fc27a4a88a2bfd9122ced21920791 |
refs/heads/master | <repo_name>davisgrubin/district_tweets<file_sep>/GeoStream.py
import os
import tweepy
import DistrictDict as dd
import sys
import jsonpickle
dist_dict = dd.get_files()
dist_lookup = []
for k, v in dist_dict.items():
dist_lookup.append((v,k))
TWITTER_APP_KEY = os.environ['TW_CONSUMER_KEY']
TWITTER_APP_SECRET ... | de7c56978c5be2e0150a54ad646831144b04459c | [
"Markdown",
"Python"
] | 8 | Python | davisgrubin/district_tweets | 1180fca455b7ed3321e12c1d7bc477db052dfb1e | c9ff1593f16ae36988ebfb45e60dba73b898d278 |
refs/heads/master | <repo_name>clube-do-malte/checkout<file_sep>/Carrinho.php
<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Carrinho extends Model
{
protected $table = "Carrinho";
protected $fillable = [
'id_trayCorp',
'nome',
'email',
'telefone',
'valor',
... | 1bc084f40fc973314ce65b04f583e39f4395d28e | [
"Markdown",
"PHP"
] | 6 | PHP | clube-do-malte/checkout | 232e00c6e1549ccb960caa714ef523334cb2b181 | ade490de7915905d678ade33bf7db25af7b0d1f4 |
refs/heads/main | <file_sep>import React from 'react';
import closeIcon from '../../icons/closeImage.png';
import onlineIcon from '../../icons/onlineImage.png';
import './InfoBar.css';
const InfoBar = ({room}) => (
<div className = "infoBar">
<div className = "leftInnerContainer">
<img className = "onlineIcon"... | a1bc47ede23119218dd1a57b4119055e057cf623 | [
"JavaScript",
"Markdown"
] | 4 | JavaScript | sanchay9/rchat | 187abe9a43ba2387d5528febe63fe8c148c4b66f | ffc3e23aae06276896a9f3cf3d812dbf381a7dba |
refs/heads/master | <file_sep>import Button from '@material-ui/core/Button';
import Dialog from '@material-ui/core/Dialog';
import DialogContent from '@material-ui/core/DialogContent';
import DialogContentText from '@material-ui/core/DialogContentText';
import DialogTitle from '@material-ui/core/DialogTitle';
import Grid from '@material-u... | 2a4286b637b1a69564ded59a31a0349db0f23311 | [
"JavaScript"
] | 5 | JavaScript | entrepreneurgivingcircle/giving-circle.com | b379a7822b2ffc0d0c143bfbdce70490781dbac1 | bae4759f260473ff41b4fb874acc0289ca41fb7f |
refs/heads/master | <file_sep>
from __future__ import print_function
import datetime
from google.auth import default, iam
from google.auth.transport import requests
from google.oauth2 import service_account
from googleapiclient.discovery import build
from oauth2client.service_account import ServiceAccountCredentials
CLOUD_FUNCTION = Fals... | bebfe730fd5a4ec88fba4cb532d1b2ee67655089 | [
"Python"
] | 1 | Python | sheemat/UnUsedUsers | 8046524b6c1e97e3e169c78643b626dfcbce3a89 | 96442d45ad6d9d90a2ebf1fa9f9cb4d01defa13d |
refs/heads/master | <file_sep>__author__ = 'tal'
from myrubik import *
def problem1():
cube1 = createCube()
R2U(cube1, 0)
F2U(cube1, 1)
R2U(cube1, 1)
R2F(cube1, 2)
R2U(cube1, 0)
F2U(cube1, 1)
U2R(cube1, 2)
R2U(cube1, 0)
return cube1
def problem2():
cube1 = createCube()
R2U(cube1, 0... | 4bf16c2d573454743624ba00281874f9fd94a8b0 | [
"Python"
] | 4 | Python | ttaallll/MyRubikCube | 21f49faba0f5b8943fce919cc7c7d98871e3be55 | 28bd47fabb2e6cfeba49152f4f16528eee76b96c |
refs/heads/master | <repo_name>KonradJanica/react-datetime-pickers<file_sep>/example/src/App.js
import React from 'react'
import DateTimePicker from 'react-datetime-pickers'
import 'react-datetime-pickers/dist/index.css'
import './App.scss'
const App = () => {
const [selected, setSelected] = React.useState(new Date());
const [selecto... | ace966ac3627891443cdbf34fb444406083473fd | [
"JavaScript",
"Markdown"
] | 3 | JavaScript | KonradJanica/react-datetime-pickers | 581166080526394b4ce4938cbb601eba843ce085 | d4525a6dbabcd71fb6d674a1daa15cc8384ab9a6 |
HEAD | <file_sep>//
// Constants.swift
// StoreApp
//
// Created by yuaming on 12/07/2018.
// Copyright © 2018 yuaming. All rights reserved.
//
import Foundation
enum FileTypes {
case json
var name: String {
switch self {
case .json: return "json"
}
}
}
struct Constants {
static let storeList = "... | 78530845a45142ffb4ad1e4059d2f31d88b3315f | [
"Swift",
"Ruby",
"AsciiDoc"
] | 26 | Swift | yuaming/swift-storeapp | 449f5bd47c2c3c6a0411c4b6cc1cb2dda52adcd9 | 0487a3de79a387b9e6e2654e95083241044c3e0e |
refs/heads/main | <repo_name>JimvandeVen/portfolio-sterrk<file_sep>/frontend/src/components/Tech.js
import { gql, useQuery } from "@apollo/client";
import styled from "styled-components";
export const ALL_TAGS_QUERY = gql`
query ALL_TAGS_QUERY {
allTags {
id
name
}
}
`;
const StyledTech = styled.div`
display:... | 1464053f5f218e824d8d7ed4e581e62ad601f838 | [
"JavaScript",
"Markdown"
] | 11 | JavaScript | JimvandeVen/portfolio-sterrk | 352a57f978170210f6ab5bfd5e42101568eb8041 | 75c2412d07c426df0bb6beccf95ed4fc15454f0d |
refs/heads/master | <repo_name>IlMike22/PiggyBank<file_sep>/app/src/main/java/com/mwidlok/piggybank/MainActivity.kt
package com.mwidlok.piggybank
import android.support.v7.app.AppCompatActivity
import android.os.Bundle
import android.util.Log
import com.mwidlok.piggybank.models.Transaction
import kotlinx.android.synthetic.main.activity_m... | 5d13fac86fe7d69f8916a38b3dfdf853e4194e2b | [
"Kotlin"
] | 2 | Kotlin | IlMike22/PiggyBank | 4577422b5bd2146a76df7ca74ab5a93f0be9819e | bfc3d4ee67f371b7c93912c6a3eb9639e95266f7 |
refs/heads/main | <repo_name>zshaikhonline/GraphQL-with-Spring-Boot<file_sep>/README.md
# GraphQL with Spring Boot
Graphql with springboot
<file_sep>/src/main/java/com/graphqlservices/graphql/model/Student.java
package com.graphqlservices.graphql.model;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConst... | cc3aa3498088b817e20b3140516e814121cf8835 | [
"Markdown",
"Java"
] | 5 | Markdown | zshaikhonline/GraphQL-with-Spring-Boot | 3c188b1aa3471d84d8be63f2bb6488eee3fb77ae | e10a05c0075b9efa6b697c7153de69fdd609642c |
refs/heads/master | <file_sep>package AbstractClasss;
abstract class figure {
double dim1;
double dim2;
public figure(double a, double b) {
dim1 = a;
dim2 = b;
}
abstract double area();
}
class rectangle extends figure {
public rectangle(double a, double b) {
super(a, b);
// TODO Auto-generated constru... | 42b641bedcd2b1ffbf9c5959b4cb0c2b5612f01a | [
"Java"
] | 1 | Java | AshwiniQualityAnalyst/AbstractClasses | 01b0b1df81e3cb01ed83c3c7fe4c570a830195a4 | f50cd48e70eda9a03ba0206b9a6943db3941f150 |
refs/heads/master | <repo_name>kenzosakiyama/visao_computacional<file_sep>/utils.py
import numpy as np
from PIL import Image
def histogram_from_grayscale(img: Image) -> np.array:
histogram = np.zeros(256)
# Reshape para facilitar iteração
img_array = np.asarray(img).flatten()
histogram, _ = np.histogram(img_array, 256,... | 2a231750cb5f6facf31fd81791e30dbdabb0a89a | [
"Python"
] | 1 | Python | kenzosakiyama/visao_computacional | a93fbb8b109f87d41302270ebe1a89aff2d88396 | 48e162200057f54150a83136a37ecf9fba32a8ae |
refs/heads/master | <repo_name>ethankclam/coursera-test<file_sep>/site/javascript/script.js
// DOM Manipulation
// console.log(document.getElementById("title"));
// console.log(document instanceof HTMLDocument);
// object creation
// var company = new Object();
// company.name = "Facebook";
// company.ceo = new Object();
// company.ceo.... | 2d606c9a57a1c22c416b8cf422e3a3c6461f168d | [
"JavaScript"
] | 1 | JavaScript | ethankclam/coursera-test | b084cd4e254cf5129b2469e64e915e07b3a8280c | 296589981f28f1cce129018e093a514fc5c9115b |
refs/heads/master | <file_sep>/*
* Start point for application
*/
#include <QtGui>
#include "powerstatus.h"
#include "thinkpadbattery.h"
int main(int argc, char *argv[])
{
Q_INIT_RESOURCE(ThinkPadBattery);
PowerStatus powerStatus;
QApplication app(argc, argv);
if (!QSystemTrayIcon::isSystemTrayAvailable()) {
... | 6dc41953a7e8507357043edd6106476ae78dc37b | [
"Makefile",
"C++"
] | 6 | C++ | edghto/ThinkPadBatteryTray | 245270acb41813efb8c439effe0e4cab108c0968 | 5c4d0111314e961178be4d3a2f212bffaf4d6510 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.