content stringlengths 10 4.9M |
|---|
<reponame>FredrikBlomgren/aff3ct<filename>include/Module/Decoder/LDPC/BP/Horizontal_layered/Decoder_LDPC_BP_horizontal_layered_inter.hpp
/*!
* \file
* \brief Class module::Decoder_LDPC_BP_horizontal_layered_inter.
*/
#ifndef DECODER_LDPC_BP_HORIZONTAL_LAYERED_INTER_HPP_
#define DECODER_LDPC_BP_HORIZONTAL_LAYERED_INT... |
export declare const SIG_CONFIG: {
1: {
sigLength: number;
pubLength: number;
};
2: {
sigLength: number;
pubLength: number;
};
3: {
sigLength: number;
pubLength: number;
};
};
|
package cla.edg.project.optical.gen.graphquery;
import java.util.Map;
import cla.edg.modelbean.*;
public class Prescription extends BaseModelBean {
public String getFullClassName() {
return "com.doublechaintech.optical.prescription.Prescription";
}
// 枚举对象
// 引用的对象
public AgeRange ageRange() {
Ag... |
<gh_stars>1-10
package org.kyojo.schemaorg.m3n3.core;
import org.kyojo.schemaorg.CamelizedName;
import org.kyojo.schemaorg.ConstantizedName;
import org.kyojo.schemaorg.JsonLdContext;
import org.kyojo.schemaorg.SampleValue;
import org.kyojo.schemaorg.SchemaOrgComment;
import org.kyojo.schemaorg.SchemaOrgLabel;
import o... |
Maybe it’s the economy, or the current state of politics, or our recent boy band resurgence—but for whatever reason, Americans are putting down the milk and picking up the wine glass. Consumption of milk, soda and juice has dropped since 2001, while consumption of alcohol has increased. Market Watch broke down our liba... |
import math
m,n,k = map(int,raw_input().split())
ansp = None
if k%2==0:
ansp = "R"
else:
ansp = "L"
d = math.ceil(k/(2*n*1.0))
l = math.ceil((k-((d-1)*2*n))/(2*1.0))
print int(d),int(l),ansp |
/**
*
* @author James Ahlborn
*/
public class NumberFormatter
{
public static final RoundingMode ROUND_MODE = RoundingMode.HALF_EVEN;
/** designates the format of exponent notation used by ScientificFormat */
public enum NotationType {
/** Scientific notation "E", "E-" (default java behavior) */
EXP_E... |
/**
* Sort array using merge sort algorithm
*
* @example
* mergeSort([ 3, 2, 5, 9, 7 ]) -> [2, 3, 5, 7, 9]
*/
export const mergeSort = (arr: number[]): number[] => {
if ( arr.length < 2 ) { return arr }
const mid = Math.floor( arr.length / 2 )
const left = arr.slice(0, mid)
const right = arr.slice(mid)
... |
package main
import (
"fmt"
)
const size = 400
const numLocs = 50
var centers [numLocs + 1]coord // index 0 is not used
func abs(i int) int {
if i < 0 {
return -i
}
return i
}
type coord struct {
x int
y int
}
func dist(c1, c2 coord) int {
return abs(c2.x-c1.x) + abs(c2.y-c1.y)
}
func distancesSum(c coo... |
/**
* The Agreement resource. Represents the details of certification provided by the partner.
*/
public class Agreement
extends ResourceBase
{
/**
* Gets or sets the Object identifier of the logged in user in the partner tenant
* who is providing confirmation on behalf of the partner organizati... |
/**
* This coordinator class is in charge of the workflow sending Settlement messages to aggregators.
*/
@Singleton
@TransactionAttribute(TransactionAttributeType.REQUIRED)
public class DsoSendSettlementMessagesCoordinator {
private static final Logger LOGGER = LoggerFactory.getLogger(DsoSendSettlementMessagesCo... |
Explaining implementation behaviour of the National Incident Management System (NIMS).
This paper explains the perceived implementation behaviour of counties in the United States with respect to the National Incident Management System (NIMS). The system represents a massive and historic policy mandate designed to rest... |
def find_live_model(
models: List[KonanModel],
) -> str:
for model in models:
if model.state == KonanModelState.Live:
return model.uuid
return None |
package com.zte.ums.bcp.orm.framework.sql.service;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
import com.zte.ums.bcp.orm.exception.OrmException;
import com.zte.ums.bcp.orm.framework.request.entry.RequestQueryRecord;
import com.zte.ums.bcp.orm.framework.sql.keyword.MySqlK... |
<filename>fs/tty.cc
#include <errno.h>
#include <fs/dev.h>
#include <fs/devnum.h>
#include <fs/ioctl.h>
#include <fs/stat.h>
#include <fs/tty.h>
#include <kernel.h>
#include <lib/murmur.h>
#include <lib/string.h>
#include <lib/unordered_map.h>
using namespace libcxx::placeholders;
namespace filesystem
{
namespace ter... |
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { jqxDropDownListComponent } from 'jqwidgets-scripts/jqwidgets-ts/angular_jqxdropdownlist';
import { jqxLayoutComponent } from 'jqwidgets-scripts/jqwidgets-ts/angular_jqxlayout';
import { jqxDataTableComponent }... |
/*----------------------------------------------------------------------------*/
/* Copyright (c) 2018-2019 FIRST. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of... |
FTC To Payment Processor: You Are Liable For The “Google Money Tree”, A $15 Million Dollar Scam.
As more and more startups race to be payment processors, the FTC (US Federal Trade Commission) is racing to hold payment processors 100% liable for the activities of the merchants they process for. This is a huge responsib... |
Punjab News Express/Satinder Bains
CHANDIGARH: The leading English newspaper The Tribune which had carried reports of alleged involvement of former SAD minister Bikram Singh Majithia in synthetic drug racket has apologized from the latter for falsly blaming him. The Tribue said there is no evidence of involvement of B... |
<filename>e2e/internal/e2e/imageverify.go
// Copyright (c) 2021 Apptainer a Series of LF Projects LLC
// For website terms of use, trademark policy, privacy policy and other
// project policies see https://lfprojects.org/policies
// Copyright (c) 2019, Sylabs Inc. All rights reserved.
// This software is licensed u... |
def init_stage2_at_from_stage1(df_stage2, share_num):
df_stage1 = get_last_stored_df(share_num, 1)
for col in at_columns.AT_STAGE1_CARRY_FORWARDS:
try:
colnum = df_stage2.columns.get_loc(col)
stage1_series = df_stage1[col].resample('B', label='left', origin='start_day').sum()
... |
def plot_euler_error(df):
plt.title('euler angle errors')
np.rad2deg(df.t_vehicle_attitude_0__f_roll_error).plot(
label='roll error', style='r-')
np.rad2deg(df.t_vehicle_attitude_0__f_pitch_error).plot(
label='pitch error', style='g-')
np.rad2deg(df.t_vehicle_attitude_0__f_yaw_error).plo... |
/**
* List all spells in the given book.
*
* @param book The book to be read.
* @param spells The list of spells to populate. Doesn't have to be empty.
* @return Whether the given book is invalid (empty).
*/
static bool _get_book_spells(const item_def& book, spell_set &spells)
{
int num_spell... |
import simpy
import json
import time
import datetime
from pydblite.sqlite import Database, Table
from dateutil import parser
import sys
import click
import paho.mqtt.client as mqtt
env = None#simpy.Environment()
context={}
def get_sim_time(step_time):
start_time = context['start_time']
actual_time = start_ti... |
/**
* Application launching code for AddVectorREEF.
*/
public final class AddVectorET {
/**
* Should not be instantiated.
*/
private AddVectorET() {
}
/**
* Runs app with given arguments.
* @param args command line arguments for running app
* @return a LauncherStatus
*/
public static Lau... |
/* not longer used sender should be real sydner in p2pSyncInfos*/
public String convertP2PSyncInfoToJsonUsingStreaming(List<P2PSyncInfo> p2PSyncInfos) {
String json = "";
try {
Gson gson = this.registerP2PSyncInfoBuilder();
SyncInfoMessage message = new SyncInfoMessage("syncInfoM... |
import sys
def write(text):
if text.endswith("\n") is False:
text += "\n"
sys.stderr.write(text)
sys.stderr.flush()
class Echo(object):
def send(self, timestamp, metrics, dimensions):
width = 50
fill = "#"
write(" dimensions ".center(width, fill))
for key, val... |
<gh_stars>1-10
package lkd.namsic;
import android.Manifest;
import android.annotation.SuppressLint;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.text.method.ScrollingMovementMethod;
import android.view.View;
import android.widget.Button;
import android.widget.... |
Recombinant factor VIIa (eptacog alfa): a pharmacoeconomic review of its use in haemophilia in patients with inhibitors to clotting factors VIII or IX.
Recombinant factor VIIa (NovoSeven; also known as recombinant activated factor VII or eptacog alfa) is indicated as an intravenous haemostatic agent in haemophilia pat... |
//checks that output files with reasonable file sizes are generated, but correctness of output is not checked
@Test()
public void testCNVPlotting() {
final File outputDir = createTempDir("testDir");
final String[] arguments = {
"-" + ExomeStandardArgumentDefinitions.TANGENT_NORMALIZE... |
////////////////////////////////////////////////////////////////////////////////
// Copyright (c) 2016, Andrew Dornbush
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
// 1. Redistribut... |
<filename>test/examples/regression/issue310_nested_class_name/issue310_nested_class_name.py<gh_stars>10-100
import unittest
import issue310_nested_class_name_boost_python as boost
class TestIssue310(unittest.TestCase):
def _test_issue310(self, binding):
self.assertTrue(hasattr(binding.Base, 'Option'))
... |
package db
import (
"fmt"
"io/ioutil"
"os"
"path/filepath"
"testing"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
cmn "github.com/tendermint/tendermint/libs/common"
)
func cleanupDBDir(dir, name string) {
os.RemoveAll(filepath.Join(dir, name) + ".db")
}
func testBackendGetSetD... |
<reponame>errwiinn/PBO<gh_stars>0
package jfo7.pkg2;
public class PrisonTest {
public static void main(String[] args) {
//exercise 1
Prisoner bubba = new Prisoner();
Prisoner twitch = new Prisoner();
System.out.println(bubba == twitch);//false
//exercise 2
bubba.n... |
<filename>nav/src/headers_parsers.hpp
// Copyright (c) 2021 midnightBITS
// This code is licensed under MIT license (see LICENSE for details)
#pragma once
#include <tangle/base_parser.hpp>
#include <tangle/nav/headers.hpp>
#include <tangle/str.hpp>
namespace tangle::nav {
int is_http_tchar(int c) noexcept;
int is_... |
/**
* Set the order by column for this query.
*
* @param column
* @param ASC
* @param limit
*/
public void orderby(String column, boolean ASC, int limit) {
this.orderByColumn = column;
this.orderByASC = ASC;
this.orderByLimit = limit;
} |
/**
* Created by hxl on 2017/1/3 at haiChou.
*/
public class MineRecyclerAdapter extends RecyclerView.Adapter<MineRecyclerAdapter.MyHolder> {
private RecyclerView mRecyclerView;
private List<Integer> data = new ArrayList<>();
private List<String> title = new ArrayList<>();
private Context mContext;
... |
#pragma once
#include <map>
#include "http_parser.h"
#include "Url.hpp"
#include "../Channel.hpp"
/// Get HTTP error category
error_category &getHttpCategory();
///
/// Communication channel for HTTP/1.1
class HttpChannel : public Channel {
public:
// HTTP methods such as GET and POST
enum class Method {
#defin... |
/**
* @brief Construct a `pool_memory_resource` and allocate the initial device memory pool using
* `upstream_mr`.
*
* @throws rmm::logic_error if `upstream_mr == nullptr`
* @throws rmm::logic_error if `initial_pool_size` is neither the default nor aligned to a
* multiple of pool_memory_resource::allo... |
A rider is a contractual proviso that outlines a series of stipulations or requests between at least two parties. While they can be attached to leases and other legal documents, they’re most famously used by musicians or bands to outline how they need their equipment to be set up and arranged, how they like their dress... |
/* eslint-disable */
export { fetchMaterialsImportant, mapFetchedPosts } from './asyncActions';
export { materialsImportantReducer, resetMaterialsImportant } from './reducers';
export { selectMaterialsImportant } from './selectors';
|
R = lambda: map(int, input().split())
s = list(input())
l = len(s)
L = [[] for i in range(l)]
c = 0
for i in range(l):
L[i].append(c)
if 'a' <= s[i] <= 'z':c += 1
c = 0
for i in reversed(range(l)):
L[i].append(c)
if 'A' <= s[i] <= 'Z':c += 1
mi = sum(L[0])
for i in range(1,l):
mi = min... |
# -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: mediapipe/framework/formats/annotation/locus.proto
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobu... |
After approval from the Austin police union, a proposed five-year police employment contract is now ready to go to the Austin City Council, which will decide whether to implement it or scrap it.
The proposed deal, approved by 85 percent of the union members, would raise officers’ base pay 9.5 percent over five years. ... |
// this function deletes all the existing states of BB
// except the very first state. This state is renamed
// to LEGUP_loop_pipeline_wait.
// All instructions are deleted from this state - so it is empty
// This state has two transitions:
// pipeline_finish is false: loop back to itself
// pipeline_finish is ... |
<reponame>AgentMax05/cpp_chess_bot<gh_stars>1-10
#include "board.h"
#include "move_generation.h"
#include "set_attacking.h"
bool king_check(Board board, bool isWhite) {
if (isWhite) {
if ((board.kingW & board.attackB).none() == false) {return true;}
} else {
if ((board.kingB & board.attackW).no... |
Dell executives have been saying they plan to sell off some assets as the company prepares to buy data storage giant EMC for an industry-record $67 billion. They took a significant step March 28, when NTT Data announced it was buying Dell's IT services business for what reportedly is about $3.05 billion.
Officials wit... |
/*******************************************************************************
*
* Function l2cu_process_our_cfg_req
*
* Description This function is called when we send a "config request"
* message. It extracts the configuration of interest and saves
* it in the C... |
<reponame>lejeunel/glia<filename>src/hmt/bc_feat.cxx
#include "bc_feat.hxx"
// Follow arXiv paper
void glia::hmt::selectFeatures (
std::vector<FVal>& f, BoundaryClassificationFeats const& bcf)
{
int size = f.size() + 5 + 4 * bcf.x0.region.size() +
2 * bcf.x0.labelRegion.size();
#ifdef GLIA_USE_MEDIAN_AS_FE... |
Samina Sundas, founder of American Muslim Voice, attends a vigil to honor the 49 people killed in the shooting in Orlando, Fla., and call for a ban on assault weapons. Photo by Molly Riley/UPI | License Photo
Protesters take part in a die-in to demonstrate against the shooting in Orlando and call for a ban on assault ... |
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
package org.mozilla.gecko.sync.net;
import java.io.BufferedReader;
import java.io.IOException;
import java.lang.r... |
// End completes array encoding.
func (a *ArrayEncoder) End() error {
a.decIndent()
if a.len < 0 {
if err := a.writeNewLine(); err != nil {
return err
}
if err := a.writeMarker(arrayEndMarker); err != nil {
return err
}
} else if a.len != a.count {
return fmt.Errorf("unable to end array of length %d ... |
class Hit_effects:
"""
Describes a visual effect when the player hits an obstacle like a tree, rock, or bush. Draw method which draws the effect onto the screen.
"""
path = r'level_1/Utils/Pics/Obstacles/Effects/'
list_of_imgs = os.listdir(path)
num_of_imgs = len(list_of_imgs)
imgs = [pygame.image.load(r'level_... |
WATSONVILLE – A Santa Cruz man was shot in the leg during an attempted robbery outside Markley’s Indoor Range and Gun Shop Sunday afternoon, police said.
The 38-year-old victim was with his father-in-law when the two left the range about 2 p.m., after some recreational shooting, and had secured their firearm as requir... |
/** Create the window/level result image. */
private final RenderedImage windowLevelOperator(RenderedImage source,
double low,
double high) {
if ( source == null ) {
return null;
}
ParameterBlock pb = null;
RenderedImage dst = null;
SampleModel sampleModel... |
Early childhood parenting and child impulsivity as precursors to aggression, substance use, and risky sexual behavior in adolescence and early adulthood
Abstract The current study utilized a longitudinal design to explore the effect of early child impulsivity and rejecting parenting on the development of problematic b... |
/** Computes the luminance from the given r, g, and b in accordance with
SK_LUM_COEFF_X. For correct results, r, g, and b should be in linear space.
*/
static inline U8CPU SkComputeLuminance(U8CPU r, U8CPU g, U8CPU b) {
return (r * 54 + g * 183 + b * 19) >> 8;
} |
/**
* Overridden to update the session state prior to saving if any attribute value has a different
* hash code than it used to. This allows us to detect changes when a mutable object is used as
* an attribute value.
*/
@Override
protected void complete()
{
... |
def match(cls, message):
if not message.startswith('s/'):
return
parts = re.split(r'(?<!\\)/', message)
if len(parts) not in (3, 4):
return
search, replace = parts[1:3]
if len(parts) == 4:
flags = parts[3]
else:
flags = ''
... |
<filename>cottonformation/res/greengrassv2.py
# -*- coding: utf-8 -*-
"""
This module
"""
import attr
import typing
from ..core.model import (
Property, Resource, Tag, GetAtt, TypeHint, TypeCheck,
)
from ..core.constant import AttrMeta
#--- Property declaration ---
@attr.s
class PropComponentVersionComponentPl... |
s = str(input())
d = {'':1}
d2 = {}
for i in range(len(s)):
for k, v in d.items():
temp = k+s[i]
if temp not in d2:
d2[temp] = v
else:
d2[temp] += v
if s[i] not in d:
d[s[i]] = 1
else:
d[s[i]] += 1
#print(d)
#print(d2)
print(max(d2.values()))
|
<commit_msg>fix(core/presentation): Remove return value from useEffect in useMountStatusRef
<commit_before>import { useEffect, useRef } from 'react';
export function useMountStatusRef() {
const mountStatusRef = useRef<'FIRST_RENDER' | 'MOUNTED' | 'UNMOUNTED'>('FIRST_RENDER');
useEffect(() => {
mountStatusRef.c... |
<filename>src/server/modules/logger/types/log.ts
export enum LogLevel {
DEBUG = 'debug',
ERROR = 'error',
INFO = 'info',
LOG = 'log',
WARN = 'warn',
}
export enum LogCode {
REQUEST = 0,
EXCEPTION = 1,
HTTP_SUCCESS = 2,
HTTP_FAILURE = 3,
GRAPHQL_ERROR = 4,
}
export interface LogMessage {
// Requir... |
#include<bits/stdc++.h>
using namespace std;
#define Speed_UP ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
typedef long long ll;
#define pb push_back
#define rep(i,n) for(int i=0;i<n;i++)
#define MAXN 1000001
int spf[MAXN];
void sieve()
{
spf[1] = 1;
for (int i=2; i<MAXN... |
/*
Resize a clusterchain. Returns the new last cluster or 0 if it was not possible to resize
*/
private long resizeClusterChain(long lastCluster)
{
long lbaFATLastCluster = getEntryLBA(lastCluster);
byte[] data = readBytes(lbaFATLastCluster, 1);
int sectorIndex = getEntrySectorIn... |
while True:
try:
p,q=map(int,raw_input().split())
except EOFError:
break
S,L=[],[]
while True:
L.append(p/q)
amari=p%q
if amari in S:
S.append(amari)
break
S.append(amari)
p=amari*10
if S[-1]==S[-2]==0:
print "".join(ma... |
"""Author: <NAME>, Copyright 2019"""
import tensorflow as tf
import nltk
import numpy as np
import argparse
import os
from collections import defaultdict
if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument(
"--min_frequency",
type=int,
... |
def _check_for_residual_space(self):
covered_volume = sum(rect.volume for rect in self.hyperrectangles)
if not np.isclose(covered_volume, 1):
raise ValueError("The passed in rectangles do not cover "
"all of [0,1]^n") |
A Working Research Prototype of an ISDN Central Office
This paper describes a working research prototype of an ISDN central office which demonstrates the key hardware and software elements needed for ISDN services. As such, it does not include all the normal trappings of a central office such as maintenance or non-ISD... |
/**
* Fit a polynomial curve to a GTS
*/
public class POLYFIT extends NamedWarpScriptFunction implements WarpScriptStackFunction {
public POLYFIT(String name) {
super(name);
}
@Override
public Object apply(WarpScriptStack stack) throws WarpScriptException {
Object top = stack.pop();
boolean use... |
/**
* Check if timestamp is faulty
*
* @param gpsTime gps timestamp
* @param referenceTime reference system time
* @return true if faulty
*/
public static boolean isGpsClockFaulty(final long gpsTime, final long referenceTime) {
return ((gpsTime > GpsRolloverConstants.getFirst... |
<reponame>stanislawbartkowski/reactrestapi<filename>dist/components/panel/panelcomp/TopBar.tsx<gh_stars>0
import React, { FunctionComponent } from 'react';
import Grid from '@mui/material/Grid';
import TopLabel from './topbar/TopLabel'
import DBName from './topbar/DBName'
import ActionLabel from './topbar/ActionLabel... |
Adaptive Curvature-Sensitive Meshing of the Medial Axis
The medial axis transform provides an alternative r epresentation of geometric models that has many use ful properties for analysis modelling. Applications include decomposition of ge neral solids into sub regions for mapped meshing, i dentification of slender re... |
def download_all_bank_statement(period):
user_filepath = DATA_ROOT_DIR_PATH + 'registration/user_list.csv'
user_list = list(pd.read_csv(user_filepath, header=None).values)[0]
bank_filepath = DATA_ROOT_DIR_PATH + 'registration/bank_list.csv'
bank_list = list(pd.read_csv(bank_filepath, header=None).values... |
<reponame>Eraylee/nest-personal-blog
import { IsNotEmpty, IsDefined, IsInt } from 'class-validator';
import { Transform } from 'class-transformer';
import { ApiModelProperty } from '@nestjs/swagger';
import { FileEntity } from '../file.entity';
export class CreateFileDto {
readonly buffer: any;
readonly enc... |
// HTMLLine renders a diff solution into a before and after string.
// Words are added one at a time, and changes are marked with spans.
func HTMLLine(d *delta.DiffSolution) (string, string) {
a := &bytes.Buffer{}
b := &bytes.Buffer{}
for _, word := range d.Lines {
switch delta.LineSource(word[2]) {
case delta.L... |
/**
* policy level elements
*
*/
@Generated("jsonschema2pojo")
public class Policy {
/**
* A unique 4-digit code assigned by the Statistical Bureaus to identify each insurance company.
*
*/
@SerializedName("CompanyID")
@Expose
private String companyID;
/**
* A code identify... |
<filename>lib/kv/dummy.d.ts
declare var DummyKvResource_1: any;
export { DummyKvResource_1 as DummyKvResource };
|
/**
* "actionParams": [
{
"paramName": "ID",
"paramDesc": "Unique Identitifer",
"paramDefault": "3fee7fa1-655f-484e-9ff4-57ddbb8349ff",
... |
// AssignPropertiesToServerPrivateEndpointConnectionPropertiesStatus populates the provided destination ServerPrivateEndpointConnectionProperties_Status from our ServerPrivateEndpointConnectionProperties_Status
func (properties *ServerPrivateEndpointConnectionProperties_Status) AssignPropertiesToServerPrivateEndpointCo... |
/** Test case for
* <a href="https://issues.apache.org/jira/browse/CALCITE-4644">[CALCITE-4644]
* Add PERCENTILE_CONT and PERCENTILE_DISC aggregate functions</a>. */
@Test void testPercentileCont() {
final String sql = "select\n"
+ " percentile_cont(0.25) within group (order by deptno)\n"
+ "f... |
<reponame>esjx/homebridge-esjx
/// <reference types="node" />
declare type Binary = Buffer | NodeJS.TypedArray | DataView;
export declare type BinaryLike = string | Binary;
export declare const BASE_UUID = "-0000-1000-8000-0026BB765291";
export declare function generate(data: BinaryLike): string;
export declare functio... |
<gh_stars>0
#pragma once
template <typename T> class Node final{
public:
T data;
Node<T> *left{nullptr};
Node<T> *right{nullptr};
Node(const T& _data):data(_data){}
Node() = default;
~Node() = default;
};
template<typename T, typename Node = N... |
// find the max depth of binary number, inturn which means max of decimal number
public int maxDepth(int[] nums) {
int max = 0;
for (int num : nums) {
max = Math.max(max,num);
}
return Integer.toBinaryString(max).length();
} |
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
ECPDBDomainIntegrator ecpdbDomainIntegrator = new ECPDBDomainIntegrator();
ecpdbDomainIntegrator.PDB2ECAndInterPro();
Map<String, TreeMap<String, Set<String>>> map = ecpdbDomainIntegrator.getMap();... |
Metastatic Liver Disease: Indications for Locoregional Therapy and Supporting Data.
Metastatic liver disease is a major cause of cancer-related morbidity and mortality. Surgical resection is considered the only curative treatment, yet only a minority is eligible. Patients who present with unresectable disease are trea... |
//checks is a string belongs to the body
private boolean isBody(String s){
if(isInnerText(s) | PARAB.legal(s) |NEWLINE.legal(s))
return true;
return false;
} |
// Load resets the state of the lexer and prepares it to tokenise the source
// code in the given byte scanner.
func (l *Lexer) Load(r io.ByteScanner) {
l.r = r
l.pos = position{line: 1, col: 0}
l.curr = token.Token{Kind: token.EOF}
l.next = token.Token{Kind: token.EOF}
l.err = nil
if l.r != nil {
_, _ = l.Cons... |
def delete_music(artist_id, music_id):
error = False
try:
music = Music.query.get(music_id)
music_type = music.type_
music_title = music.title
db.session.delete(music)
db.session.commit()
response = {"success": True}
except Exception:
error = True
... |
<filename>src/Numeric/ER/RnToRm/UnitDom/ChebyshevBase/Polynom/Integration.hs
{-# LANGUAGE FlexibleContexts #-}
{-|
Module : Numeric.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Integration
Description : (internal) integration of polynomials
Copyright : (c) 2007-2009 <NAME>
License : BSD3
... |
package cn.pzhu.forum.dao;
import cn.pzhu.forum.entity.UserInfo;
import org.apache.ibatis.annotations.*;
import org.springframework.stereotype.Repository;
import java.util.List;
@Mapper
@Repository
public interface UserInfoDao {
/**
* 查询用户信息
*
* @param id 用户ID
* @return 用户信息
*/
@Sel... |
/*-
* <<
* UAVStack
* ==
* Copyright (C) 2016 - 2017 UAVStack
* ==
* 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 r... |
// buildColumns build column name list
func buildColumns() {
Columns = make(map[string][]string)
for _, schema := range Schemas {
table := fmt.Sprintf("`%s`.`%s`", schema.Table.Schema.String(), schema.Table.Name.String())
for _, col := range schema.Cols {
Columns[table] = append(Columns[table], fmt.Sprintf("`%... |
/**
* @author Darren Greaves
*/
public class CollectionsInterfaceTest extends Flickr4JavaTest {
@Test
public void testGetInfo() throws FlickrException {
CollectionsInterface iface = flickr.getCollectionsInterface();
Collection collection = iface.getInfo(testProperties.getCollectionId()... |
//=== itoa_ljust.cpp - Fast integer to ascii conversion --*- C++ -*-//
//
// Substantially simplified (and slightly faster) version
// based on the following functions in Google's protocol buffers:
//
// FastInt32ToBufferLeft()
// FastUInt32ToBufferLeft()
// FastInt64ToBufferLeft()
// FastUInt64To... |
/**
* Opens the file given in the constructor and creates an ArrayList of the stopwords the
* file contains
*/
public class StopWords {
ArrayList <String> stopwords = new ArrayList<String>();
public StopWords(String filepath)
{
// The name of the file to open.
String fileName = ... |
import React from 'react';
import mailImage from '../../assets/mail-image.svg';
import { Container, Input, Button } from './styles';
const NewsletterSection: React.FC = () => {
return (
<Container>
<div className="newsletter-section">
<div className="newsletter-container">
<img src={mai... |
Uber is the darling of Democrats and Republicans alike, but the company’s cutthroat campaign against its ride-share rivals could land it in hot water with state and federal regulators.
The company has reportedly equipped an army of independent contractors with burner phones and credit cards as pa... |
The Markov-Switching Multifractal Model of Asset Returns
Multifractal processes have recently been proposed as a new formalism for modeling the time series of returns in finance. The major attraction of these processes is their ability to generate various degrees of long memory in different powers of returns—a feature... |
BRAND NEW PUBLICATION | Launching 21st April 2017
We are excited to announce the launch of our brand new magazine Rolls-Royce & Bentley Driver!
Celebrating two of the greatest luxurious car brands to grace our roads, this comprehensive publication takes a look at some of the most popular versions from both Rolls-Royc... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.