content stringlengths 10 4.9M |
|---|
{-# LANGUAGE
DeriveGeneric
, DeriveTraversable
, TypeFamilies
, FlexibleInstances
, UndecidableInstances
, MultiParamTypeClasses
#-}
module Types where
import GHC.Generics
import Data.Aeson
import Data.Ix
import Data.Array.Unboxed
type Board = UArray Cell Bool
data Input = Input
{ id :: Int
, uni... |
The statement below was released by the Party of the Labouring Masses (PLM), a Filipino socialist group, on July 1.
* * *
The PLM condemns any moves to pave the way for the return of US military base facilities in the Philippines. This includes giving the US access to Philippine military bases and facilities at Clark... |
<gh_stars>1-10
/*
* Copyright 2019 The Android Open Source Project
*
* 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 requ... |
/**
* Compute a single byte array message for a node and its children.
* Using {@code taskIdToBytes}, we pack all messages for a
* {@code TopologySimpleNode} and its children into a single byte array.
*
* @param node the target TopologySimpleNode to generate a message for
* @param taskIdToBytes map co... |
// TODO: Overload hello() three times
class Human
{
public:
void Hello(Human human) { std::cout << "Hello Human! \n"; }
} |
def horizontal_scan_grad(self, row_index):
for i in range(1, self.width):
hor_grad = self.assess_gradient(self.image[row_index][i-1], self.image[row_index][i])
self.edges[row_index][i] = max(self.edges[row_index][i], hor_grad) |
/* Helper for the key generation/edit functions. */
static void show_card_key_info(struct agent_card_info_s *info) {
tty_fprintf(NULL, "Signature key ....:");
print_sha1_fpr(NULL,
(const unsigned char *)(info->fpr1valid ? info->fpr1 : NULL));
tty_fprintf(NULL, "Encryption key....:");
print_sha... |
<reponame>kshedden/muscato
// Copyright 2017, <NAME> and the Muscato contributors.
// test is a script that runs a series of unit tests on the Muscato
// code base.
//
// To run the tests, use:
//
// go run test.go
package main
import (
"bufio"
"fmt"
"io"
"io/ioutil"
"log"
"os"
"os/exec"
"path"
"strings"
... |
<filename>actor/v7action/task.go
package v7action
import (
"strconv"
"sort"
"code.cloudfoundry.org/cli/actor/actionerror"
"code.cloudfoundry.org/cli/api/cloudcontroller/ccerror"
"code.cloudfoundry.org/cli/api/cloudcontroller/ccv3"
)
// Task represents a V3 actor Task.
type Task ccv3.Task
// RunTask runs the p... |
A new study that tracked 15,000 students since their sophomore year in high school in 2002 until now has found that poor students who planned to get college degrees fell far below their own expectations—leaving an even greater gap in graduation rates than in enrollment between them and their wealthier counterparts.
Th... |
def fetch_group_members(self, group_id):
result = self._get(self._group_url(group_id, '/members'))
return deserialize.group_members(result) |
/* Copyright (C) 2005-2011 M. T. Homer Reid
*
* This file is part of SCUFF-EM.
*
* SCUFF-EM is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any lat... |
package com.zw.protocol.msg.t809.body.module;
import lombok.Data;
import org.apache.commons.lang3.StringUtils;
/**
* @Description:
* @Author:nixiangqian
* @Date:Create in 2018/10/17 14:39
*/
@Data
public class EnterpriseInfo {
/**
* 企业名称
*/
private String name;
/**
* 运输行业
*/
... |
(Photo: I-5 Design & Manufacture)Operating a workplace as a democracy in the contemporary business world isn’t easy, Morgan says, but worker cooperatives are showing the way while thriving and multiplying.
Creating a new economy within the confines of predatory capitalism is an immense undertaking. The various oppress... |
#include <bits/stdc++.h>
using namespace std;
#define MAX 3001
#define ll int
const ll INF = 999999999LL;
ll n;
bool ok;
ll s[MAX],c[MAX];
ll memo[MAX][MAX][4];
ll dp(int i,int j,int k){
if(i>n){
if(k<3){
return INF;
}
else {
ok=true;
return 0;
}
}
if(memo[i][j][k]!=-1)return memo... |
<filename>src/third_party/wiredtiger/src/os_win/os_map.c
/*-
* Copyright (c) 2014-present MongoDB, Inc.
* Copyright (c) 2008-2014 WiredTiger, Inc.
* All rights reserved.
*
* See the file LICENSE for redistribution information.
*/
#include "wt_internal.h"
/*
* __wt_win_map --
* Map a file into memory.
*/
... |
Mobile defects born from an energy cascade shape the locomotive behavior of a headless animal
The physics of behavior seeks simple descriptions of animal behavior. The field has advanced rapidly by using techniques in low dimensional dynamics distilled from computer vision. Yet, we still do not generally understand th... |
After the wild success of the Disney Channel’s first “Descendants” movie, one of the most watched cable TV movies in recent years, a script for a sequel has been commissioned, it was announced today.
It is already cable television’s fifth highest-rated movie of all-time and Disney is eager to grow the franchise.
“By ... |
A Comparison of Computer-Assisted and Self-Management Programs for Reducing Alcohol Use among Students in First Year Experience Courses
The National Institute of Alcohol Abuse and Alcoholism has called for the use of evidence-based approaches to address high-risk drinking prevalent on many college campuses. In line wi... |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import {DataType} from '../../../wasm-common';
import {TensorView} from '../../tensor';
import {PoolConvUtil} from '../../util';
import {AttributeWithCacheKey, createAttributeWithCacheKey} from '../attribute-with-cache-key'... |
// Copyright (c) 2011 The LevelDB Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. See the AUTHORS file for names of contributors.
//
// An iterator yields a sequence of key/value pairs from a source.
// The following class defines the... |
package com.thealgorithms.maths;
import static org.junit.jupiter.api.Assertions.*;
import org.junit.jupiter.api.Test;
public class VolumeTest {
@Test
public void volume() {
/* test cube */
assertTrue(Volume.volumeCube(7) == 343.0);
/* test cuboid */
assertTrue(Volume.volume... |
<filename>src/state/api_set.cc
//
// Created by 方泓睿 on 2020/4/10.
//
#include <embryo/state/lua_value.h>
#include <embryo/state/lua_state.h>
#include <embryo/state/lua_table.h>
#include <embryo/state/lua_value.h>
namespace embryo::state {
void LuaState::SetTable(int64_t idx) {
auto t = stack_->Get(idx);
auto v = ... |
/**
* Build the routing from {@link IndexMetadata}.
*/
public static IndexRouting fromIndexMetadata(IndexMetadata metadata) {
if (false == metadata.getRoutingPaths().isEmpty()) {
return new ExtractFromSource(metadata);
}
if (metadata.isRoutingPartitionedIndex()) {
... |
import { useTranslation } from 'next-i18next';
interface AlertProps {
onClose?: () => void;
type: 'error' | 'warning';
message: string;
}
function Alert(props: AlertProps): JSX.Element {
const { t } = useTranslation(['index', 'errors']);
let spanStyle = 'bg-red-100 border border-red-400 text-red-7... |
Share. The end is here for Emily. The end is here for Emily.
There will be no more revenging for Emily Thorne, as ABC has cancelled Revenge after four seasons. EW broke the news, revealing that the season finale on May 10th will also function as a series finale.
Executive producer Sunil Nayar told EW, “We can officia... |
/*A word or a sentence in some language is called a pangram if all the characters of the alphabet of this language appear in it at least once. Pangrams are often used to demonstrate
fonts in printing or test the output devices.
You are given a string consisting of lowercase and uppercase Latin letters. Check whether ... |
<reponame>douglasdsda/Proffy<gh_stars>1-10
import { Router } from 'express';
import ResetPasswordController from '../../controllers/ResetPasswordController';
const resetPasswordRouter = Router();
const resetPasswordController = new ResetPasswordController();
resetPasswordRouter.post('/', resetPasswordController.crea... |
When the transfer window opens in July, Orlando City star forward Cyle Larin will be the latest player to find himself in the middle of the tug-of-war between the interests of Major League Soccer, Orlando City and his own personal goals.
It’s a path familiar to just about any player who has been transferred out of the... |
<filename>cache_level2/follow.go<gh_stars>1-10
package cache_level2
import (
"database/sql"
"gitlab.com/stihi/stihi-backend/app"
)
/*
func (dbConn *CacheLevel2) SaveFollowFromOperation(op *types.FollowOperation, ts time.Time) (int64, error) {
// Все проверки на уровне cache_level1
var id int64
// Получаем id юз... |
/**
* <pre>
* WithdrawShare defines a method for withdrawing a share from a bond that is in the SETTLE stage.
* </pre>
*/
public void withdrawShare(ixo.bonds.Tx.MsgWithdrawShare request,
io.grpc.stub.StreamObserver<ixo.bonds.Tx.MsgWithdrawShareResponse> responseObserver) {
asyncUnaryCa... |
/**
* :: Experimental ::
* A label indexer that maps a string column of labels to an ML column of label indices.
* If the input column is numeric, we cast it to string and index the string values.
* The indices are in [0, numLabels), ordered by label frequencies.
* So the most frequent label gets index 0.
* <p>
... |
We reported earlier that THQ has declared bankruptcy and is now seeking a new owner. But one of the unfortunate realities of such a miserable situation is having to declare all of your assets. And in a game company's case, that means revealing every game you've got in development. There are four titles we didn't know a... |
Transport properties of nitrogen in single walled carbon nanotubes.
Transport properties including collective and tracer diffusivities of nitrogen, modeled as a diatomic molecule, in single walled carbon nanotubes have been studied by equilibrium molecular dynamics at different temperatures and as a function of pressu... |
/**
* Reason for a specific bound on a variable.
*
* The reason can be a literal that was set by the dpll engine
* ({@link LiteralReason}) or it is a composite reason ({@link CompositeReason})
* build from the sum of other reasons.
* Each LinVar keeps a list of reasons for upper and lower bounds, starting
* w... |
<reponame>eugenecartwright/hthreads
const char pride[] = "\
The Project Gutenberg EBook of Pride and Prejudice, by <NAME>\n\
(#8 in our series by <NAME>)\n\
\n\
Copyright laws are changing all over the world. Be sure to check the\n\
copyright laws for your country before downloading or redistributin... |
This product features a beautiful walnut bentwood frame with glossy black leather upholstery. This chair is sure to make an impression and become the focal point in your office or home office. Having the support of an ergonomic office chair may help promote good posture and reduce future back problems or pain. High bac... |
// Copyright 2014 Wandoujia Inc. All Rights Reserved.
// Licensed under the MIT (MIT-LICENSE.txt) license.
package binlog
import (
"bufio"
"bytes"
"fmt"
"math"
"math/rand"
"net"
"strconv"
"testing"
"time"
"github.com/wandoulabs/codis/extern/redis-port/pkg/libs/errors"
"github.com/wandoulabs/codis/extern/r... |
Hockey athletes may want to check their equipment before they go out onto the ice. A recall is out for Bauer Hockey gear, due to a laceration hazard.
The recall involves:
-Cages on the Concept C1 Goal Mask with Certified Titanium Oval Wire
-NME 10 Goal Mask with Certified Titanium Oval Wire
-RP NME Ti Titanium Repl... |
/// Get another mutable reference `NodeMut`, borrowing out the current one
pub fn as_mut<'b>(&'b mut self) -> ComponentRefMut<'b, B, C> {
ComponentRefMut {
n: self.n.as_mut(),
phantom_data: PhantomData,
}
} |
/**
* https://issues.apache.org/jira/browse/WICKET-3929
*
* @author Carl-Eric Menzel
*/
class PropertyModelWithListTest
{
/** */
static class BeansContainer
{
private List<Bean> beans = new ArrayList<Bean>();
/**
* @return the beans
*
*/
List<Bean> getBeans()
{
return beans;
}
/**
... |
One of the many benefits of the Web is the ability to create unique, personalized experiences for individual users. We believe that this personalization needs to be done with respect for the user – with transparency, choice and control. When the user is at the center of product experiences everyone benefits.
Over the ... |
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by <NAME>.
//
#import "NSObject.h"
#import "VCAudioIODelegate.h"
#import "VCAudioIOSink.h"
#import "VCAudioIOSource.h"
#import "VCMediaStreamProtocol.h"
#import "VCTextSender.h"
@class NSObject<OS_di... |
/**
* ggu class global comment. Detailled comment
*/
public class DbOperatorValues {
protected List<IDbOperator> operators = new ArrayList<IDbOperator>();
public DbOperatorValues() {
init1();
init2();
init3();
}
protected void init1() {
operators.add(getDefaultOperat... |
<gh_stars>1000+
package com.zendesk.maxwell.schema.columndef;
import java.math.BigDecimal;
public class DecimalColumnDef extends ColumnDef {
private DecimalColumnDef(String name, String type, short pos) {
super(name, type, pos);
}
public static DecimalColumnDef create(String name, String type, short pos) {
De... |
Optics of sunlit water drops on leaves: conditions under which sunburn is possible.
*It is a widespread belief that plants must not be watered in the midday sunshine, because water drops adhering to leaves can cause leaf burn as a result of the intense focused sunlight. The problem of light focusing by water drops on ... |
/* ============================================================================
* Project Name : ezbox Configuration Daemon
* Module Name : init.c
*
* Description : ezbox initramfs init program
*
* Copyright (C) 2008-2013 by ezbox-project
*
* History Rev Description
* 2011-10-29 0.1 Write ... |
Last week I was flipping through a small notebook and found some notes for the idea of making a bacon straw. Finding ourselves with bacon in the house last weekend we decided to try it.
We cooked them on a cooling rack over a cookie sheet to allow the fat to drain. 325 for about 15 minutes.
The original idea was to m... |
def close_later(handler):
if not isinstance(handler, logging.Handler):
raise TypeError("handler must be a logging.Handler instance")
no_delay = 0.0
return _FLUSH_THREAD.submit(handler.close, no_delay) |
/****************************************************************************
* <b>Title</b>: ISBNTest.java
* <b>Project</b>: SMT-Kata
* <b>Description: </b> test case for the kata ISBN class
* <b>Copyright:</b> Copyright (c) 2021
* <b>Company:</b> Silicon Mountain Technologies
*
* @author James Camire
* @vers... |
Destructive Knee Joint Infection Caused byPeptostreptococcus micros: Importance of Early Microbiological Diagnosis
ABSTRACT Peptostreptococcus micros is a commensal of the oral cavity and the genitourinary tract that rarely causes serious infections. A case of a destructive knee joint infection with rapid progress cau... |
def repeats(database, semester):
data = database
data = data.reset_index(drop=True)
repeats = {}
bol = True
df = data[semester + '_STUDENT_ID']
toExport = pd.DataFrame(data)
toExport = toExport.iloc[0:0]
i = 0
while (i < len(df)):
if (i in df.index):
ID = df[i]
... |
// Helper function to ensure that a dir name/path will be valid on the OS
String OS::get_safe_dir_name(const String &p_dir_name, bool p_allow_dir_separator) const {
Vector<String> invalid_chars = String(": * ? \" < > |").split(" ");
if (p_allow_dir_separator) {
invalid_chars.push_back("..");
} else {
invalid_cha... |
// KVs returns a metadata map for structured logging
func (err *SupervisorStartError) KVs() map[string]interface{} {
acc := make(map[string]interface{})
acc["supervisor.name"] = err.supRuntimeName
if err.nodeErr != nil {
var subTreeError ErrKVs
if errors.As(err.nodeErr, &subTreeError) {
for k0, v := range sub... |
/*
Let temporary file replace old file.
This assumes that the new file was created in the same
directory as given by realpath(filename).
This will ensure that any symlinks that are used will still work.
Copy stats from old file to new file, deletes orignal and
changes new file name to old file name
*/
int m... |
/**
* An executor that is constructed with two output executors. All
* push/close calls called on this executor or reproduced on the
* two input executors.
*/
public final class Splitter implements Executor {
private final Executor out1;
private final Executor out2;
public Splitter(Executor out1, Executor out... |
#/bin/python3
import numpy as np
from PIL import Image
def processbad(array):
#arr = np.zeros([array.size(),array[0].size(),array[0][0].size])
arr = np.zeros([int(np.size(array)/8),
int(np.size(array[0])/8),3],
dtype=np.byte)
# print (arr)
counter = 0
count = 0
for i in array:
... |
// NewPacProxyHTTPServerWithPath is a convenience function to create an instance of
// PacProxyHTTPServer with a local PAC file.
func NewPacProxyHTTPServerWithPath(path string) (*PacProxyHTTPServer, error) {
parser := new(gopac.Parser)
err := parser.Parse(path)
if err != nil {
return nil, err
}
return NewPacProx... |
Rajesh De, the NSA’s former top lawyer, recently announced that he would step down. (Courtesy of law firm Mayer Brown)
The top lawyer for the National Security Agency, Rajesh De, has stepped down from his post and will join the law firm Mayer Brown.
De’s last day was Friday, and he plans to start at Mayer Brown in Ju... |
/* Construct and send a packet of data of type CMD and len
LEN_NOHEADER (not counting the header...). */
static void
hw_rv_send (struct hw *me,
unsigned int cmd,
void *msg,
unsigned int len_noheader)
{
hw_rv_device *rv = (hw_rv_device *) hw_data (me);
unsigned8 buf[32+3];
unsigned8 *bufp;
uns... |
import { Injectable } from 'angular2/core';
import { CARDS } from '../../mocks/cards/mock-cards';
@Injectable()
export class CardService {
getCards() {
return Promise.resolve(CARDS);
}
getCardsByClassName(name: string)
{
switch (name)
{
case 'Druid': return this.getCardsByClassId(1);
... |
def alert_should_be_present(self, text=''):
alert_text = self.get_alert_message()
if text and alert_text != text:
raise AssertionError("Alert text should have been "
"'%s' but was '%s'"
% (text, alert_text)) |
<reponame>bencampion/regxmllib
/*
* Copyright (c) 2014, <NAME> (<EMAIL>)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright... |
/*************************************************************************
* Copyright 2020 Gravwell, Inc. All rights reserved.
* Contact: <<EMAIL>>
*
* This software may be modified and distributed under the terms of the
* MIT license. See the LICENSE file for details.
*******************************************... |
/* Copyright (C) 2010-2019, The Regents of The University of Michigan.
All rights reserved.
This software was developed as part of the The Vulcan project in the Intelligent Robotics Lab
under the direction of <NAME>, <EMAIL>. Use of this code is governed by an
MIT-style License that can be found at "https://github... |
/**
* Created by boeselager on 11.01.17.
*/
public class ResourceHelpers {
public static List<Resource> unwrapRecords(List<Resource> aRecords) {
List<Resource> resources = new ArrayList<>();
for (Resource rec : aRecords) {
resources.add(unwrapRecord(rec));
}
return resources;
}
public st... |
/**
* touch command, set access/modify time or create new file
*
* @param cmdArray command line array
* @param root file system root node
*/
public static void touch(String[] cmdArray, HNode root) {
var cmdList = Arrays.asList(cmdArray);
if (cmdArray.length == 1 || cmdList.c... |
<reponame>randomicon00/rust<gh_stars>1000+
// run-rustfix
#![allow(unused)]
#![warn(clippy::derive_partial_eq_without_eq)]
// Don't warn on structs that aren't PartialEq
struct NotPartialEq {
foo: u32,
bar: String,
}
// Eq can be derived but is missing
#[derive(Debug, PartialEq)]
struct MissingEq {
foo: ... |
x=input()
for i in range(0,x):
t=map(int,raw_input().split())
a=len(str(t[1]))
if t[1]==9*int(a*"1"):
print t[0]*a
else:
print t[0]*(a-1)
|
def lambda_handler(event, context):
arn = event["SecretId"]
token = event["ClientRequestToken"]
step = event["Step"]
os.environ["LD_LIBRARY_PATH"] = "./:$LD_LIBRARY_PATH"
secrets_manager_client = boto3.client(
"secretsmanager", endpoint_url=os.environ["SECRETS_MANAGER_ENDPOINT"]
)
di... |
// Commit commits the transaction.
func (tx *Transaction) Commit() error {
if tx.ro {
tx.Rollback()
return ErrReadOnly
}
if err := tx.Tx.Commit(); err != nil {
tx.Rollback()
return errors.Wrap(err, "failed to rollback")
}
return tx.Rollback()
} |
# Treasures, Demons, and Other Black Magic
### Dowser 3
## Meghan Ciana Doidge
#### Old Man in the CrossWalk Productions
### Contents
Author's Note
Introduction
Chapter 1
Chapter 2
Chapter 3
Chapter 4
Chapter 5
Chapter 6
Chapter 7
Chapter 8
Chapter 9
Chapter 10
Chapter 11
Chapter 12
Chapter 13
Cha... |
<filename>cmd/singlepage/main.go
package main
import (
"errors"
"fmt"
"io"
"os"
"zgo.at/singlepage"
"zgo.at/zli"
)
const usage = `usage: singlepage [flags] file.html
Bundle external assets in a HTML file to distribute a stand-alone HTML document.
https://github.com/arp242/singlepage
The -local, -remote, and ... |
Automatic Car Parking with Arduino, LDR Sensor
Now days it is very important to save the time, money in terms of travelling and parking too. If any one goes to the shopping, people didn’t know, is there any space to the vehicle parking or not,in such a cases to save the public time, automatic car parking helps. Workin... |
// Uses batch inversion across all instances in the batch.
fn apply_partial_batch(vec_state: &mut [Vec<F>]) {
// Apply the S-BOX to the first elements of each of the state vector
let mut w: Vec<F> = Vec::new();
let mut accum_prod = F::one();
w.push(accum_prod);
// Calculate the i... |
/**
* Tests peer authentication with basic mirror authentication
*/
@Test
public void testPeerMirrorAuthentication() throws InterruptedException {
Random random = new Random(randomSeed);
final int N_PACKETS = 10;
final int MIN_PACKET_SIZE = 1;
final int MAX_PACKET_SIZE = 10... |
/*
* Queue an action. Takes the plugin configuration, the Kerberos context, the
* principal, the operation, and a password (which may be NULL for enable and
* disable). Returns a Kerberos error code.
*/
krb5_error_code
sync_queue_write(kadm5_hook_modinfo *config, krb5_context ctx,
krb5_principal ... |
<reponame>lesspointless/Shakal-NG
# -*- coding: utf-8 -*-
from django.apps import AppConfig as BaseAppConfig
from django.utils.module_loading import autodiscover_modules
class AppConfig(BaseAppConfig):
name = 'fulltext'
verbose_name = "Fulltext"
def ready(self):
autodiscover_modules('fulltext_search')
|
package constant
type Stat string
const (
AgilityStat Stat = "agility"
AttackStat Stat = "attack"
HullStat Stat = "hull"
ShieldsStat Stat = "shields"
PilotSkilStat Stat = "pilot_skill"
)
|
Factors contributing to the length of general practice consultations.
Ten general practitioners in a study of general practice consultations were shown to differ significantly in the time they spent in their consultations. Patient demographic characteristics contributed little to differences in consultation time. Cons... |
def create_network128():
in_image = tf.keras.Input(shape=(128, 128, 1))
leaky_relu = tf.keras.layers.LeakyReLU(alpha=0.2)
e = tf.keras.layers.Conv2D(32, (3,3), padding='same', activation=leaky_relu, kernel_initializer=tf.initializers.he_normal())(in_image)
e = tf.keras.layers.AveragePooling2D()(e)
... |
<reponame>justlesq/stomweb<filename>src/main/java/com/sohu/stom/modules/order/entity/OrderDetail.java
/**
* Copyright © 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
*/
package com.sohu.stom.modules.order.entity;
import org.hibernate.validator.constraints.Length;
impor... |
package com.centurylink.mdw.boot.servlet;
import java.io.File;
import java.io.IOException;
import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.se... |
A U.S. District Judge has sentenced Jonathan Schwatz, the former business manager who stole millions of dollars from Alanis Morissette and his other clients, to six years in prison today. The sentence came after Morissette testified at Schwatz’s hearing, presumably keeping one hand in her pocket, and the other on the B... |
def __validate_objects_between_tables(page1, page1_table, page2, page2_table, header_footer_type: HeaderFooterType):
header_footer_height = header_footer_type.value/11
table1_end_y = page1_table.geometry.polygon[2].y
if any(1-header_footer_height > line.geometry.polygon[2].y > table1_end_y for line in page1... |
<reponame>wigforss/spring-nats
package org.kasource.spring.nats.message.serde.xml;
import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.Map;
import java.util.Optional;
import java.util.concurrent.ConcurrentHashMap;
import javax.xml.XMLConstants;
import javax.xml.bind.annot... |
<reponame>jhhuh/franz
{-# LANGUAGE RecordWildCards #-}
module Database.Franz.Internal.IO (getInt64le, runGetRecv, hGetRange) where
import Data.IORef
import Data.Serialize hiding (getInt64le)
import Data.Typeable (cast)
import Foreign.Ptr
import Foreign.ForeignPtr
import Foreign.C.Types
import GHC.IO.Exception
import G... |
<gh_stars>0
import requests, xmltodict, xmltodict, json, unicodedata
import sys
print(sys.getdefaultencoding())
# XML url
XML_URL = 'https://raw.githubusercontent.com/servicosgovbr/cartas-de-servico/master/cartas-servico/v3/lista-completa-servicos.xml'
# Get XML from URL
with requests.Session() as session:
reque... |
/*
* reset and start the controller registers
*/
void azx_init_chip(struct azx *chip, bool full_reset)
{
if (snd_hdac_bus_init_chip(azx_bus(chip), full_reset)) {
if (chip->driver_caps & AZX_DCAPS_CTX_WORKAROUND)
azx_writew(chip, RINTCNT, 0xc0);
}
} |
The New Jersey Devils’ line in the NHL standings may be the saddest thing in the hockey world.
They sit at 34-29-16, good for 84 points in 79 games, which leaves them three points behind Columbus for the final Eastern Conference playoff spot. Despite a late surge, time is running out, and the Devils will almost certai... |
// Copyright 2021 <NAME>
#include <gtest/gtest.h>
#include <gtest-mpi-listener.hpp>
#include "./reshetka_tor.h"
TEST(Cor_Tor, Creat_Tor) { // Create tor topology
int ProcRank, ProcNum;
MPI_Comm_rank(MPI_COMM_WORLD, &ProcRank); // Poluchenie ranka
MPI_Comm_size(MPI_COMM_WORLD, &ProcNum); // Poluchenie kol-vo r... |
// run-pass
// Test that coercing bare fn's that return a zero sized type to
// a closure doesn't cause an LLVM ERROR
// pretty-expanded FIXME #23616
struct Foo;
fn uint_to_foo(_: usize) -> Foo {
Foo
}
#[allow(unused_must_use)]
fn main() {
(0..10).map(uint_to_foo);
}
|
/**
* <p>Computes a G (Log-Likelihood Ratio) two sample test statistic for
* independence comparing frequency counts in
* {@code observed1} and {@code observed2}. The sums of frequency
* counts in the two samples are not required to be the same. The formula
* used to compute the test statistic ... |
#ifndef XXHR_BEARER_H
#define XXHR_BEARER_H
#include <string>
#include "defines.hpp"
namespace xxhr {
/**
* \brief Some Web APIs requires authenticating via HTTP Basic auth ( *i.e.* base64 encoded user and password authentication).
*
* \copydoc authentication-cpp
*
*/
class Bearer {
public:
//! Token fo... |
import sun.misc.Cleaner;
public class Room implements AutoCloseable {
private final Cleaner cleaner ;
private static class State implements Runnable{
int numJunPiles ;
public State(int numJunPiles) {
this.numJunPiles = numJunPiles;
}
@Override
public void ... |
<reponame>BSFrance/BSFrance<gh_stars>1000+
#ifndef _SYS_FCNTL_H_
#define _SYS_FCNTL_H_
#include <sys/_default_fcntl.h>
/* We want to support O_BINARY for the open syscall.
For example, the Demon debug monitor has a separate
flag value for "rb" vs "r". */
#define _FBINARY 0x10000
#define O_BINARY _... |
Calcium-dependent myosin from insect flight muscles.
Calcium regulation of the insect actomyosin ATPase is associated with the thin filaments as in vertebrate muscles, and also with the myosin molecule as in mollusks. This dual regulation is demonstrated using combinations of locust thin filaments with rabbit myosin a... |
def crypto_bloom_filter(record: Sequence[Text],
comparators: List[AbstractComparison],
schema: Schema,
keys: Sequence[Sequence[bytes]],
) -> Tuple[bitarray, Text, int]:
hash_l = schema.l * 2 ** schema.xor_folds
bloom... |
// Concord
//
// Copyright (c) 2018 VMware, Inc. All Rights Reserved.
//
// This product is licensed to you under the Apache 2.0 license (the "License").
// You may not use this product except in compliance with the Apache 2.0 License.
//
// This product may include a number of subcomponents with separate copyright
// ... |
#include <iostream>
#include <list>
#include <string>
using namespace std;
class CPerson;
class CStudent;
class CTeacher;
class CVisitor;
class CPrinter;
//element to be visited
class CPerson //pure virtual class
{
protected:
string name;
int gender;
CPerson() {}
public:
virtual void Accept(CV... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.