text
stringlengths
1
1.05M
// Create a shopping list in the variable myList. The list should be a // multi-dimensional array containing several sub-arrays. // The first element in each sub-array should contain a string with the name of /the item. The second element should be a number representing the quantity i.e. // ["Chocolate Bar", 15] /...
#!/bin/bash # dumps out the log files according to the provided pattern, but makes sure that # each one is dumped in chronological order, and any compressed logs are unpacked # first. function assemble_log_file() { logpath="$1"; shift # build an array of all the file names, in reverse order since we want the old...
APP_NAME=dprweb OUTDIR="${1:-../../build}" SOURCEDIR="${2:-$OUTDIR/..}" rm -f $OUTDIR/$APP_NAME.zip # generate the ZIP file echo "Generating $APP_NAME.zip... ($SOURCEDIR -> $OUTDIR)" pushd $SOURCEDIR zip -r $OUTDIR/$APP_NAME.zip * -x \*.git\* -x \*node_modules\* *.zip popd if hash notify-send 2>/dev/null; then n...
from zDogPy.illustration import Illustration from zDogPy.shape import Shape eggplant = '#636' orange = '#E62' start = { 'x' : -60, 'y' : -60 } startControl = { 'x' : 20, 'y' : -60 } endControl = { 'x' : -20, 'y' : 60 } end = { 'x' : 60, 'y' : 60 } I = Illustration() I.setSize(200, 200) # cur...
<gh_stars>0 package com.ruoyi.file.service.impl; import cn.hutool.core.io.FileUtil; import cn.hutool.core.util.IdUtil; import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.ZipUtil; import cn.hutool.http.HttpUtil; import com.aliyun.oss.OSSClient; import com.aliyun.oss.model.PutObjectResult; import com.qiniu.u...
const { Command, MayfiEmbed, MiscUtils } = require('../../') const fetch = require("node-fetch") module.exports = class Cat extends Command { constructor (client) { super({ name: 'cat', aliases: ['meow'], category: 'fun', }, client) } async run ({ channel, author, t}) { const body ...
<filename>web/BookReader/BookReaderInit.js // // This file shows the BookReader initial configuration // // Copyright(c)2008-2009 Internet Archive. Software license AGPL version 3. // Create the BookReader object br = new BookReader(); br.mode = display_mode; // Return the width of a given page. Here we ass...
<filename>test/test.js var chai = require("chai"), expect = chai.expect, assert = chai.assert, sinonChai = require('sinon-chai'), sinon = require('sinon'); var helper = require('../lib/helper'), calc = require('../lib/calc'); chai.use(sinonChai); describe('Helper',function(){ describe('#log()',...
#!/bin/bash # Copyright 2019 - 2020 Crunchy Data Solutions, Inc. # 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 applicabl...
<gh_stars>1-10 /* Created by <NAME> on 30/11/16. */ package main.scala.slaves import java.util.concurrent.LinkedBlockingQueue import scala.collection.mutable.ListBuffer import scala.util.control.Breaks._ class SummerClass(queue: LinkedBlockingQueue[Double]) extends Runnable { val batch_size = 3200 private val sh...
def print_string(text): if len(text) > 0: print(text) else: raise Exception('The input string is empty')
<filename>acmicpc.net/source/9506.cpp // 9506. 약수들의 합 // 2019.05.22 // 수학 #include<iostream> #include<vector> #include<algorithm> using namespace std; int main() { while (1) { int n; cin >> n; if (n == -1) { break; } vector<int> v; // 자기 자신을 제외한 약수 저장 v.push_back(1); for (int i = 2; i*i <= n...
#!/bin/bash # CUDA # Patch CUDA so that we can use clang 11 FILE=/usr/local/cuda/include/crt/host_config.h BAK_FILE=/usr/local/cuda/include/crt/host_config.h.bak if [ ! -f "$BAK_FILE" ] ; then cp $FILE $BAK_FILE fi cat $BAK_FILE | sed 's,__clang_major__ >= [0-9]\+,__clang_major__ >= 20,' > $FILE
#!/bin/bash # Retrieve the IP addresses of Docker containers GUI_IP=$(/usr/bin/docker inspect --format='{{.NetworkSettings.IPAddress}}' son-gui) BSS_IP=$(/usr/bin/docker inspect --format='{{.NetworkSettings.IPAddress}}' son-bss) GTK_IP=$(/usr/bin/docker inspect --format='{{.NetworkSettings.IPAddress}}' son-gtkapi) # ...
int add(int a, int b) { int sum = 0; if (a > 0 && b > 0) { sum = a + b; } else if (a > 0) { sum = a; } else if (b > 0) { sum = b; } else { sum = 0; } return sum; }
<filename>util/serve_files.js const { join } = require('path'); const fs = require('fs'); const mime = require('mime/lite'); const { stat, readFile, readdir, mkdir, writeFile, rmdir, unlink, rename, copyFile } = fs.promises; async function sendFile(res, file, stats) { const headers = { 'Content-Length': stats.s...
<reponame>jeffrey-xiao/acm-notebook<filename>codebook/string/Z_Algorithm.cc /* * Produces an array Z where Z[i] is the length of the longest substring * starting from S[i] which is also a prefix of S. * * Time: O(N) construction * Memory: O(N) */ #include <bits/stdc++.h> using namespace std; vector...
<filename>XS_RS232_DataLogger.py #!/usr/bin/env python2 ''' Created Sep - Nov 2019 DataLogger XS60002S @author: <NAME> (CMAC, <EMAIL>, GitHub: https://github.com/frederik-d) Setup: Find Ard: ls -l /dev/ttyUSB* Enable USB: sudo chmod 666 /dev/ttyUSB1 Path: /home/pi/B290_XS_RS232_Data/XS_RS232_DataLogger.py Make shel...
import requests import bs4 url = 'https://example.com' while True: response = requests.get(url) soup = bs4.BeautifulSoup(response.text, 'html.parser') # Extract information here next_page_url = soup.find('a', {'class': 'next-page'}) if next_page_url: url = next_page_url['href'] else: break
esptool.py --port /dev/ttyUSB0 erase_flash esptool.py --port /dev/ttyUSB0 write_flash 0x1000 esp32-20180511-v1.9.4-2-g9630376d.bin
/* * * Copyright © ${year} ${name} * * 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...
ScriptInfo_backup_folder_archive_functions() { SCRIPT_NAME="Backup Folder Archive"; SCRIPT_VERSION="3.0"; SCRIPT_DATE="2020-02-20"; SCRIPT_AUTHER="Ben Batschelet"; SCRIPT_AUTHER_CONTACT="ben.batschelet@gmail.com" SCRIPT_DESCRIPTION="Used to backup a single folder" SCRIPT_TITLE="Dependency: $SCRIPT_NAME - v$...
<gh_stars>0 import { Template } from 'meteor/templating'; import { ReactiveDict } from 'meteor/reactive-dict'; import { PollingData } from '../../api/imagedata/polingdata.js'; const displayErrorMessages = 'displayErrorMessages'; Template.polls.onCreated(function onCreated() { this.messageFlags = new ReactiveDict()...
# boxes : [ quantity, boxtype, array of box names, box host] ; if box host is a string, all will be on it, if array, number must match quantity and says where each will be ansible-playbook -i inventory createdemo.yml --extra-vars='{"boxes":[{"quantity": 2, "role": "coreos", "title": ["docker-1", "docker-2"], "parent":...
const withBundleAnalyzer = require("@next/bundle-analyzer")({ enabled: process.env.ANALYZE === "true", }); const config = { pageExtensions: ["js", "jsx", "mdx"], eslint: { // Warning: Dangerously allow production builds to successfully complete even if // your project has ESLint errors. ...
<gh_stars>0 package cn.st.aop; /** * @description: * @author: st * @create: 2021-02-01 09:59 **/ public class Target implements TargetInterface{ @Override public void save() { // int i = 1/0; System.out.println("save running....."); } }
/*包含常用polyfill、常用工具函数(如ajax等)、AMD模块加载*/ /*此版本不包含DOM查询、DOM批量操作和DOM事件封装*/ var Sky=function(){ return Sky.overload(arguments,this); }; this.$=this.$ || Sky; (function(){ var rules=[]; function ckeck(ckeckFunc,index){ return ckeckFunc(this[index]); } function compare(x, y){//比较函数 return x.checks.length-y.checks.le...
#!/bin/bash # A Bash script, by Daniar # chmod 755 myscript.sh echo ================================================ echo GET NODE\'s IP echo ================================================ echo Start from node? read counter echo Finished on node? read maxNodes rm list_ip.txt while [ $counter -le $m...
def char_total(string): total = 0 for char in string: total += ord(char) return total print(char_total('Hello World!')) # Output: 1116
use std::io; use std::collections::HashMap; struct ElectionResult { voter_name: String, voted_party: String, state: String, } fn visualize_results(input_data: Vec<ElectionResult>) { let mut states_voted = HashMap::new(); for result in &input_data { // get the state name and save it in the...
<reponame>Goytai/NasaAPI import { Field, ID, ObjectType } from 'type-graphql'; import { ObjectID } from 'typeorm'; @ObjectType() export class StationsResponse { @Field(() => ID) id: ObjectID; @Field() planetName: string; @Field() createdAt: Date; }
#!/bin/bash start=`date +%s` # train CUDA_VISIBLE_DEVICES=4,5,6,7 python train.py \ --save_folder=renew_512_set2 --deploy --batch_size=32 --ssd_dim=512 --max_iter=100000 \ --prior_config=v2_512 --lr=1e-3 --schedule=60000,80000,90000 --gamma=0.5 # test CUDA_VISIBLE_DEVICES=1 python eval.py --experiment_name=renew_512...
// 17. 电话号码的字母组合 // https://leetcode-cn.com/problems/letter-combinations-of-a-phone-number/ package question17 var m = map[uint8]string{ '2': "abc", '3': "def", '4': "ghi", '5': "jkl", '6': "mno", '7': "pqrs", '8': "tuv", '9': "wxyz", } // 思路:循环调用 func LetterCombinations(digits string) []string { if len(dig...
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
<gh_stars>1-10 /* * Copyright 2021 YugaByte, Inc. and Contributors * * Licensed under the Polyform Free Trial License 1.0.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://github.com/YugaByte/yugabyte-db/blob/master/licenses...
#!/usr/bin/env bash jshint --reporter node_modules/jshint-stylish/stylish.js src/*.js cr -M 130 -C 3 -D 8 -f minimal src/*.js browserify test/*.js > test/build/bundle.js browserify -t coverify test/*.js | testling | coverify browserify -s Router src/index.js > dist/router.js uglifyjs dist/router.js -o dist/router.min....
import logging import os import shutil def copy_files_with_logging(source_dir, dest_dir): """ Copy all files from the source directory to the destination directory, preserving the directory structure. Log the details of the file copying process using the Python logging module. Args: source_dir (st...
def calculate_depth(file_path: str) -> int: # Split the file path by '/' and remove empty strings directories = [d for d in file_path.split('/') if d] # The depth is the number of directories in the path return len(directories)
package com.jensen.draculadaybyday.sql_lite; import android.os.Parcel; import android.os.Parcelable; import android.text.TextUtils; import android.util.Log; import java.util.ArrayList; import java.util.Collection; import java.util.HashMap; import java.util.LinkedList; import java.util.List; public class SqlSortFacto...
#ifndef __SSU_FILE_H__ #define __SSU_FILE_H__ #include <filesys/inode.h> #define NR_FILEDES 5 #define O_RDONLY 0 #define O_WRONLY 1 #define O_RDWR 2 #define O_APPEND 4 #define O_TRUNC 8 #define F_DUPFD 1 #define F_GETFL 2 #define F_SETFL 4 #define SEEK_SET 0 #define SEEK_CUR 1 #define SEEK_END -1 #define MAXLEN 4...
#!/bin/bash # This script contains code that should set up our scenario. cat << EOT > intro.log The courseBase.sh script for the intro has exectued in the background and this text should now appear in the file "intro.log". EOT
from django.db import models from django.conf import settings class Title(models.Model): # Define fields for the book title # ... class Review(models.Model): score = models.IntegerField(default=0) # Field for the review's score pub_date = models.DateTimeField(auto_now_add=True) # Field for the publi...
SELECT * FROM Customers ORDER BY dob DESC LIMIT 1;
project_name=php bug_id=2a6968e43a dir_name=$1/manybugs/$project_name/$bug_id download_url=https://repairbenchmarks.cs.umass.edu/ManyBugs/scenarios/php-bug-2011-02-21-2a6968e43a-ecb9d8019c.tar.gz current_dir=$PWD mkdir -p $dir_name cd $dir_name wget $download_url tar xfz php-bug-2011-02-21-2a6968e43a-ecb9d8019c.tar.gz ...
import { COIN_MAP } from './coinmap'; import { COIN_TYPE } from './cointype'; import { STATUS_CODE } from './statuscode' export { COIN_MAP,COIN_TYPE,STATUS_CODE }
pub fn calculate_average_without_outliers(data: &[f32], precision: f32) -> f32 { let mut sum = 0.0; let mut count = 0; for &value in data { let mut is_outlier = false; for &other_value in data { if value != other_value && !close(value, other_value, precision) { is...
<reponame>theutz/newinfinland.com import facepaint from 'facepaint' const font = `Tajawal, sans-serif` const color = { primary: `rgb(0, 46, 142)`, black: `#333333`, white: `#ffffff`, } const breakpoints = [769, 1024, 1216, 1408] const mq = facepaint(breakpoints.map(bp => `@media (min-width: ${bp}px)`)) expor...
#!/bin/bash # We need to install dependencies only for Docker [[ ! -e /.dockerenv ]] && exit 0 set -xe # Install git (the php image doesn't have it) which is required by composer apt-get update -yqq apt-get install git -yqq # Install phpunit, the tool that we will use for testing curl --location --output /usr/local...
<reponame>smagill/opensphere-desktop package io.opensphere.shapefile; import io.opensphere.core.Toolbox; import io.opensphere.core.datafilter.DataFilterRegistry; import io.opensphere.mantle.data.impl.DefaultDataTypeInfo; import io.opensphere.shapefile.config.v1.ShapeFileSource; /** * The Class ShapeFileDataT...
<reponame>magma/fbc-js-core /** * Copyright 2020 The Magma Authors. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distri...
<filename>admin/src/store/mutations.js<gh_stars>1-10 import storage from '@/utils/storage' export default { // 侧边栏折叠 toggleCollapse(state, isCollapse) { state.isCollapse = isCollapse }, // 是否已登录 hasLogin(state, hasLogin) { state.hasLogin = hasLogin }, // 初始化 state 中的数据 initState(state) { st...
<filename>src/models/users/response.ts import { BackGroundColorType } from "../../components/editProfile/constant"; import { SchoolType, UserType } from "../../interface/Common/user"; export interface UserSearchHistoryResponseType { keywords: Array<{ history_id: number; keyword: string; }> } e...
<gh_stars>100-1000 //----------------------------------------------------------------------------// // MODEL : OpenSOAP // GROUP : Use SAX // MODULE : CalcClientRequest.java // ABSTRACT : CalcClient for Body SOAP Message Proc. // [ ASYNC. Version ] // DATE : 2002.02....
//go:generate fyne bundle -o data.go Icon.png // Package main launches the calculator app package main import "fyne.io/fyne/v2/app" // see the readme for installation instructions func main() { app := app.New() app.SetIcon(resourceIconPng) c := newCalculator() c.loadUI(app) app.Run() }
import { notification } from 'antd'; import { Toast } from 'antd-mobile'; import { isMobileDevice } from '..'; /** * 错误处理 * 若需要判断是否为请求超时,参考 https://github.com/umijs/umi-request/issues/14 * @params error ResponseError * @params showErrorNotification boolean 是否弹出错误通知 */ const errorHandler = ({ error, showErrorN...
temp_fahrenheit=$(echo "scale = 4; $temp_celsius * 1.8000 + 32.00" | bc) echo $temp_fahrenheit
def findAnagrams(word): # Create an empty list to store anagrams anagrams = [] n = len(word) # Create a backtracking function to find an anagram def backtrack(temp, data, visited, n): # If the string formed by 'temp' is same as # the string formed by 'data', add it to anagrams ...
import random import string def generate_password(): chars = string.ascii_letters + string.digits + string.punctuation password = ''.join(random.choice(chars) for i in range(12)) return password if name == 'main': password = generate_password() print(password)
<reponame>schinmayee/nimbus<filename>applications/physbam/physbam-lib/Public_Library/PhysBAM_Fluids/PhysBAM_Compressible/Euler_Equations/EULER_CAVITATION_UNIFORM.cpp<gh_stars>10-100 //##################################################################### // Copyright 2010, <NAME>, <NAME>. // This file is part of PhysBAM...
/* * Copyright (c) Open Source Strategies, Inc. * * Opentaps is free software: you can redistribute it and/or modify it * under the terms of the GNU Affero General Public License as published * by the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * Opentap...
#!/bin/sh -- # Network interface statistics . @@CONF@@/freebsd/common.sh ${BIN_NETSTAT} -i -b -n -W -f link | ${BIN_AWK} '{ if ($1 == "Name") next; if ($1 ~ /^lo[0-9]/) next; sub(/\*$/,"",$1); printf("%s`in_bytes\tL\t%d\n", $1, $8); printf("%s`in_packets\tL\t%d\n", $1, $5); printf("%s`in_erro...
<gh_stars>1-10 export declare type Pos = { col: number; row: number; file?: string; } export declare type Token = { type: string; val: string; tagName?: string; pos: Pos; } const ifStatement_Re = /if=["][ \w=<>&.\-_'"&\(\)\|]+["]/; const ifStatement_Re_2 = /{{[ ]*if\([ \w.$\[\]"'=<>+\-,&\(\)...
Rem Rem $Header: statsdrp.sql 13-aug-99.11:17:16 cdialeri Exp $ Rem Rem statsdrp.sql Rem Rem Copyright (c) Oracle Corporation 1999. All Rights Reserved. Rem Rem NAME Rem statsdrp.sql Rem Rem DESCRIPTION Rem SQL*PLUS command file drop user, tables and package for Rem performance dia...
<gh_stars>0 -- phpMyAdmin SQL Dump -- version 4.3.8 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jun 23, 2016 at 12:17 AM -- Server version: 5.5.42-37.1-log -- PHP Version: 5.4.31 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHAR...
//Create 4 functions called add, subtract, multiply, and divide. //Create them to allow a user to perform the name of the function to the two numbers and return the result. function add(x,y) { return x + y } function subratct(x,y) { return x - y } function multiply(x,y) { return x*y } function divide(x,y) { return ...
# @author <NAME> class Array # @note Calculo del elemento maximo del array # @return [Object] Objeto del mayor dato entre los comparados def Max self.max{|a, b| a.huella_nutricional <=> b.huella_nutricional} end # @note Aumento de los precios segun el indice # @param precios Array con valores flotantes ...
const arrow = document.getElementById('arrow'); window.addEventListener("scroll", () => { var y = window.scrollY; if (y >= 600){ arrow.classList.add('opacity'); return; } else{ arrow.classList.remove('opacity'); } });
<filename>services/vsts.js // https://docs.microsoft.com/en-us/vsts/pipelines/build/variables // The docs indicate that SYSTEM_PULLREQUEST_SOURCEBRANCH and SYSTEM_PULLREQUEST_TARGETBRANCH are in the long format (e.g `refs/heads/master`) however tests show they are both in the short format (e.g. `master`) module.export...
/** * Copyright 2016 IBM Corp. All Rights Reserved. * * 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 applica...
//=require ./vendors/jquery-1.8.2.min //=require ./vendors/jquery-ui-1.8.23.min //=require ./vendors/underscore-min //=require ./vendors/backbone-min //=require ./vendors/chosen //=require ./vendors/jath //=require ./vendors/moment //=require ./vendors/jquery.clearsearch.js // //=require ./vendors/hogan-2.0.0.min //= r...
./gradlew clean build bintrayUpload -PbintrayUser=gubaojian -PbintrayKey=fb3fa84de3315230e575ba114fc38f7e36148957 -PdryRun=false
<reponame>Cribstone/home-assistant<filename>homeassistant/components/device.py """ homeassistant.components.sun ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Provides functionality to keep track of devices. """ import logging import threading import os import csv import re import json from datetime import datetime, timedelta import r...
<reponame>quenquen147/fortool-app import React, { Component } from 'react'; import { View } from 'react-native'; import { Root } from "native-base"; import { createAppContainer } from 'react-navigation'; import { createStackNavigator } from 'react-navigation-stack'; import { Ionicons } from '@expo/vector-icons'; import...
source ${0:A:h}/tests.zsh
#! /bin/sh flask db migrate flask db upgrade python3 -m flask run --host=0.0.0.0 --port=8000
<reponame>nabeelkhan/Oracle-DBA-Life -- *************************************************************************** -- File: 5_24a.sql -- -- Developed By TUSC -- -- Disclaimer: Neither Osborne/McGraw-Hill, TUSC, nor the author warrant -- that this source code is error-free. If any errors are -- ...
package logical import ( "fmt" md "github.com/jacobsimpson/mtsql/metadata" ) type Operation interface { Children() []Operation Clone(...Operation) Operation Provides() []*md.Column Requires() []*md.Column String() string } type Difference struct { LHS Operation RHS Operation } type Intersection struct { ...
package com.momo.mapper.mapper.manual; import com.momo.mapper.dataobject.LoginLogDO; public interface LoginLogMapper { int insertSelective(LoginLogDO loginLogDO); }
import Big from 'big.js'; const operate = (numberOne, numberTwo, operation) => { const a = numberOne ? Big(numberOne) : Big('0'); const b = numberTwo ? Big(numberTwo) : Big('0'); switch (operation) { case '+': return a.plus(b).toString(); case '-': return a.minus(b).toString(); case '×': ...
import React from 'react'; import { MDBBtn, MDBCard, MDBCardBody, MDBCardImage, MDBCardTitle, MDBCardText, MDBCol, MDBRow } from 'mdbreact'; const Card = (props) => { const onClickHandler = (e) => { if(props.saved){ props.bookUnsave(e) }else{ props.bookSave(e) } } return ( <MDBCol c...
#!/bin/bash set -o nounset set -o errexit cd "$(dirname "$0")" mkdir -p $PWD/../data/lib/plugins/editors/ mkdir -p $PWD/../data/lib/plugins/tools/kitPlugins/ cp $BIN_DIR/librobots-pioneer-kit.so* $PWD/../data/lib/ cp $BIN_DIR/plugins/editors/libpioneerMetamodel.so $PWD/../data/lib/plugins/editors/ cp $BIN_DIR/...
import data from '../../docs/default-firebase-data.json'; import { allKeys } from './utils'; describe('video', () => { it('matches the shape of the default data', () => { const videos = Object.values(data['videos']); const keys = ['speakers', 'thumbnail', 'title', 'youtubeId']; expect(videos...
#!/bin/bash usage() { echo " Usage: $0 HOSTNAME" exit 1 } # testar parametros [ -z $1 ] && usage # testar sintaxe valida #if [[ "$1" =~ [^a-z0-9-] ]]; then # echo " HOSTNAME must be lowercase alphanumeric: [a-z0-9]*" if [[ "$1" =~ [^a-z,A-Z,0-9-] ]]; then echo " HOSTNAME constains non-alphanumeric character...
#!/bin/bash # ========== Experiment Seq. Idx. 1645 / 30.2.1.0 / N. 0 - _S=30.2.1.0 D1_N=10 a=-1 b=1 c=-1 d=1 e=-1 f=-1 D3_N=4 g=1 h=-1 i=-1 D4_N=1 j=1 D5_N=0 ========== set -u # Prints header echo -e '\n\n========== Experiment Seq. Idx. 1645 / 30.2.1.0 / N. 0 - _S=30.2.1.0 D1_N=10 a=-1 b=1 c=-1 d=1 e=-1 f=-1 D3_N=4 g=...
export class SelectOption extends HTMLOptionElement { constructor(){ super(); this.selected = false; } static get observedAttributes() { return ['selected']; } attributeChangedCallback(attrName, oldVal, newVal){ if(name == 'selected' && oldVal != newVal){ this.selected = newVal; }...
#!/bin/bash #$ -q 1-day #$ -cwd #$ -l h_vmem=12G source $BIN_PATH/job.config if [[ -f $GATK_KEY ]]; then MUTECT="$JAVA7 -Xmx8g -jar $MUTECT_JAR -T MuTect -et NO_ET -K $GATK_KEY -log /dev/stderr --logging_level ERROR --only_passing_calls" else MUTECT="$JAVA7 -Xmx8g -jar $MUTECT_JAR -T MuTect -log /dev/...
<reponame>AakashKhatu/iDontNeedThis import requests import random def send_otp(number): url = "https://www.fast2sms.com/dev/bulk" otp = random.randint(10000, 99999) querystring = {"authorization": "<KEY>", "sender_id": "FSTSMS", "language": "english", "route": "qt", ...
def print_multiplication_table(): for i in range(1,13): for j in range(1,13): print(i*j, end="\t") print() print_multiplication_table()
function distributeHorizontalLeft(numItems: number): number[] { const positions: number[] = []; for (let i = 0; i < numItems; i++) { positions.push(i); } return positions; }
#!/bin/sh # Test is all examples in the .md files are working if [ $# -ne 1 ]; then echo "Usage: test.sh [lean-executable-path]" exit 1 fi ulimit -s unlimited LEAN=$1 NUM_ERRORS=0 for f in `ls *.md`; do echo "-- testing $f" awk 'BEGIN{ in_block = 0 } !/```/{ if (in_block == 1) print $0; else print "" } ...
<filename>sshd-sftp/src/test/java/org/apache/sshd/sftp/client/SftpOutputStreamWithChannel.java /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The AS...
public class WarningSystem { private List<String> warnings; public WarningSystem() { this.warnings = new ArrayList<>(); } // Add a warning to the system public void addWarning(String warning) { warnings.add(warning); } // Retrieve all warnings in the system public List...
<filename>tests/lib/rules/prefer-parameter-instance.spec.ts import { RuleTester } from "../../util"; import rule from "../../../lib/rules/prefer-parameter-instance"; const tester = new RuleTester({ parser: "@typescript-eslint/parser", parserOptions: { sourceType: "module", ecmaFeatures: { jsx: true,...
// Generated by CoffeeScript 1.9.1 var $, SPACES_ONLY, Serialiser, TEXT_LEADING_WHITESPACE, TEXT_TRAILING_WHITESPACE, WHITESPACE_ONLY, containsNewlines, entityDecode, exports, find, firstNonWhitespaceChild, genericBranchSerialiser, genericLeafSerialiser, joinList, last, nodeSerialisers, ref, serialise, stringEscape, ta...
/* * Copyright © 2018, 2021 Apple Inc. and the ServiceTalk project 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...
<reponame>ineunetOS/knife-commons<gh_stars>0 /* * Copyright 2013-2016 iNeunet OpenSource and the original author or 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 * * ht...
<gh_stars>100-1000 // // ZMessage.h // Zulip // // Created by <NAME> on 8/2/13. // // #import <Foundation/Foundation.h> #import <CoreData/CoreData.h> @class ZSubscription, ZUser, RawMessage; @interface ZMessage : NSManagedObject @property (nonatomic, retain) NSString * avatar_url; @property (nonatomic, retain) N...
const Discord = require('discord.js'); module.exports = { name: "help-fun", aliases: ['helpfun', 'bothelpfun'], description: "Help on the fun section", cooldown: 2, execute(message, args){ const funEmbed = new Discord.MessageEmbed() .setTitle('Commands for fun section.') .se...
<filename>src/components/RepoValidationCard.js import { useEffect, useState, useContext } from 'react' import PropTypes from 'prop-types' import { Card } from 'translation-helps-rcl' import { BIBLE_AND_OBS } from '@common/BooksOfTheBible' import { AuthContext } from '@context/AuthContext' import { StoreContext } from ...
#!/bin/sh # this tests whether all required args are listed as # missing when no arguments are specified # failure ./simple-test.sh `basename $0 .sh` test11 -v "1 2 3"