content
stringlengths
10
4.9M
To make it clear, the dialectic technical arguments he makes are all true. But half the article - as he stated himself - is just rant, pure rethoric. And I think it would be good to balance it out, which is what I will try to do in this post. Solnic is right: Ruby, by itself, has little to no future alone. Rails is a ...
// NewNode creates a new node for the graph func NewNode(id string, data interface{}) *Node { return &Node{ ID: id, Data: data, parents: make([]*Node, 0, 1), childs: make([]*Node, 0, 1), } }
// // q4.cpp // Algorithm // // Created by <NAME> on 28/10/18. // Copyright © 2018 <NAME>. All rights reserved. // array[i]*i #include<bits/stdc++.h> using namespace std; int maxSum(int arr[], int n) { sort(arr, arr + n); int sum = 0; for (int i = 0; i < n; i++) { sum += (arr[i]*i); } re...
class Evaluator: r"""Evaluates recommenders' performance against validation set. Args: ground_truth (Union[scipy.sparse.csr_matrix, scipy.sparse.csc_matrix]): The ground-truth. offset (int): Where the validation target user block begins. Often the validation ...
By Kiraz Janicke, Caracas [Read the conference declaration HERE.] November 23, 2009 – Venezuelanalysis.com – Venezuela's President Hugo Chavez called for the formation of a “Fifth International” of left parties and social movements to confront the challenge posed by the global crisis of capitalism. The president made...
/// Converts a lyon buffer into a bevy mesh. impl From<Geometry> for Mesh { fn from(geometry: Geometry) -> Self { let num_vertices = geometry.0.vertices.len(); let mut mesh = Self::new(bevy::render::pipeline::PrimitiveTopology::TriangleList); mesh.indices = Some(Indices::U32(geometry.0.indic...
import CommonBase from './CommonBase'; import * as bindings from '../bindings' // TODO: figure out location export default class C2Tuple_TxidCVec_C2Tuple_u32ScriptZZZ extends CommonBase { constructor(_dummy: object, ptr: number) { super(ptr); ...
/* * This header is generated by classdump-dyld 1.5 * on Wednesday, April 14, 2021 at 2:30:23 PM Mountain Standard Time * Operating System: Version 14.4 (Build 18K802) * Image Source: /System/Library/PrivateFrameworks/CloudKitDa...
Correction of Class II Malocclusion with Carrière Distalizer Appliance: (A case report) This article described the use of Carrière Distalizer Appliance as a method for Class II correction. A 23 year old female patient had a convex profile, a Class II malocclusion due to retrusive mandible, increased 6 mm overjet, and ...
/// Use the simplest two hex character by byte encoding fn gdb_escape(s: &[u8]) -> Vec<u8> { let mut ss = Vec::new(); for &b in s { write!(ss, "{:02x}", b).unwrap(); } ss }
<gh_stars>1-10 #include<iostream> #include<cstdio> #include<cstdlib> #include<cstring> #include<cstdlib> #include<algorithm> #include<vector> using namespace std; #define ll long long #define mem(Arr,x) memset(Arr,x,sizeof(Arr)) const int maxN=401000; const int maxAlpha=26; const int inf=2147483647; class Node { pub...
import torch import torch.nn as nn import torchvision.transforms as transforms from torchvision.datasets.folder import ImageFolder path = "./data/dogscats/sample/" batch_size=4 transform = transforms.Compose([ transforms.Scale((224, 224)), transforms.ToTensor() ]) train_dataset = ImageFolder(path + 'train',...
An advocate for B.C.'s missing women is renewing his calls for Canada's national public inquiry to investigate the mysterious deaths and disappearances of Indigenous boys and men, as well as women. Ernie Crey pushed for the creation of a national inquiry for years, after his sister Dawn's DNA was found on the farm of ...
Once Upon a Time returns to our televisions this Sunday and although I’m excited for a new trio of beautiful baddies (Maleficent, Cruella and Ursula!), my mind keeps wandering back to the first half of the season. Don’t get me wrong, I’m glad the Frozen fiasco is over. But something left me unsettled, and I think I fin...
/* * Returns 0 for success, errno value otherwise. * * If the "bind_to_req_port_only" parameter is set and the requested port * number is available, then set allocated_port to it. If not available, * return an error. * * If the "bind_to_req_port_only" parameter is not set and the requested port * number is ava...
<filename>ref/kyber/test_speed_keccak.c #include <stddef.h> #include <stdint.h> #include <stdlib.h> #include <stdio.h> #include "api.h" #include "kex.h" #include "params.h" #include "indcpa.h" #include "poly.h" #include "polyvec.h" #include "cpucycles.h" #include "speed_print.h" #include "ntt.h" #include "symmetric.h" ...
/****************************************************************************** @file rtc_test.c @brief Real Time Clock Driver Test Program DESCRIPTION Real Time Clock Driver Test Program ---------------------------------------------------------------------------- Copyright (C) 2008,2011 Qualcomm Techno...
/** * @author Tijs Rademakers */ public class ImportModelClickListener implements ClickListener { private static final long serialVersionUID = 1L; public void buttonClick(ClickEvent event) { ImportUploadReceiver receiver = new ImportUploadReceiver(); ImportPopupWindow importPopupWindow = new ImportPop...
# # Jasy - Web Tooling Framework # Copyright 2010-2012 Zynga Inc. # from jasy.js.output.Compressor import Compressor # Shared instance compressor = Compressor() pseudoTypes = set(["var", "undefined", "null", "true", "false", "this", "arguments"]) builtinTypes = set(["Object", "String", "Number", "Boolean", "Array", ...
<filename>nx-dev/ui-home/src/lib/performance.tsx import React, { ReactComponentElement, useEffect, useRef } from 'react'; import { animate, motion, MotionValue, useAnimation, useMotionValue, useTransform, } from 'framer-motion'; import { useInView } from 'react-intersection-observer'; function Counter({ ...
def _create_thin_copy_pair(self, pvol, svol): snapshot_name = _SNAP_NAME + six.text_type(svol % _SNAP_HASH_SIZE) self.run_raidcom( 'add', 'snapshot', '-ldev_id', pvol, svol, '-pool', self.conf.vsp_thin_pool, '-snapshot_name', snapshot_name, '-copy_size', self.conf.vsp...
// currently protected by w.lock of FSRecords @Override protected boolean isKeyAtIndex(byte[] value, int idx) throws IOException { myProcessingKeyAtIndex = true; try { return super.isKeyAtIndex(value, addrToIndex(indexToAddr(idx)* SIGNATURE_LENGTH)); } finally...
An Economic Evaluation of Thailand Juvenile Vocational Training Centers Themain role of the Juvenile Vocational training center is to rehabilitate young offenders and support their social reintegration, including protecting communities from unsafe situations. Imprison offenders would be faced a real challenge at the t...
<reponame>Bryambepz/InterfazAgendaTelfono<filename>src/ec/edu/ups/dao/IDAOTelefono.java /* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package ec.edu.ups.dao; import ec.edu.ups.mode...
<gh_stars>0 import React from 'react'; import { useHotkeys } from 'react-hotkeys-hook'; import { Key } from 'ts-keycode-enum'; import useSound from 'use-sound'; import useAnimation from './hooks/useAnimation'; import useField from './hooks/useField'; import { useGenericState } from './hooks/useGenericState'; import use...
One of our favorite websites, deathmetal.org has honored us with some tough questions about our trip, our lives, and our love of Metal. It is a great honor to be questioned by such a smart fellow as Brett Stevens, and be on deathmetal.org! Want to know more about ‘The Suffering and Celebration of Life in America’, our...
/** * Loads SFM Model and returns it as an EMF Resource * * @param modelFilename * @param packageNamespace * @param packageName * @return model EMF resource */ public static Resource loadSFMModelToResource(String modelFilename, String packageNamespace, String packageName) throws IOException { if (mo...
<reponame>noroot777/k package kit // InterceptDelete TODO func InterceptDelete(o *Options) { // o.stopper = make(chan struct{}) // defer func() { o.stopper <- struct{}{} }() // // o.PrintFunc = printProcess // DrawUI(o) } // func printProcess(objets []*resource.Info, txtView *ui.TextView) { // for _, obj := ran...
/** * Helper for JUnit tests. Logs the JSONs if test fails. */ public class JSONTestHelper { private static final Logger LOGGER = LogFactory.getLogger(JSONTestHelper.class); private JSONTestHelper() {} public static void shouldEqual(final JSONObject actualResponse, final JSONObject expectedResult) { ...
<reponame>semicolonDSM/DDYZD_FrontEnd<filename>pages/majorlist.tsx import Header from '@/src/components/Public/Header/Header' import MajorList from '../src/components/MajorList/MajorList' const majorlist = () => { return ( <> <Header color="white"></Header> <MajorList /> </...
package com.barofutures.seco.fragments.freemode; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.fragment.app.Fragment; import androidx.recyclerview.widget.Li...
<reponame>LGU-Web3-0/Project-Tachyon<filename>entity/src/user.rs use anyhow::anyhow; use nanorand::Rng; use sea_orm::entity::prelude::*; use sea_orm::ActiveValue; use sequoia_openpgp::packet::key::{PrimaryRole, PublicParts}; use sequoia_openpgp::parse::{Dearmor, PacketParserResult, Parse}; use sequoia_openpgp::serializ...
def max_length_pad(ls): res = -1 for l in ls: res = max(res, len(l)) return res
<reponame>twotut00/project3source package com.stylefeng.guns.rest.common.persistence.dao; import com.stylefeng.guns.api.order.vo.OrderVO; import com.stylefeng.guns.rest.common.persistence.model.MoocOrderT; import com.baomidou.mybatisplus.mapper.BaseMapper; import org.apache.ibatis.annotations.Param; import java.util....
// Creates a new connection to the Db and migrates // all the objects so that tables in the Db are created func ConnectToDB(testing bool) (*gorm.DB, error) { const dialect = "postgres" extras := "" if testing { extras += "sslmode=disable" } dbHost := os.Getenv("SAVINGS_DB_HOST") dbName := os.Getenv("SAVINGS_DB_...
MOSCOW, Russia (CNN) -- U.S. President Obama and Russian President Dmitry Medvedev concluded a series of agreements Monday -- including one on nuclear arms reduction -- as part of a broader effort to strengthen ties between the one-time Cold War rivals. President Obama and Russian President Dmitry Medvedev met in Mosc...
<reponame>alexscheitlin/caesar package ch.scheitlin.alex.build.model; import org.junit.Assert; import org.junit.Test; import java.util.ArrayList; import java.util.List; public class BuildServerBuildConfigurationTest { @Test public void getName() { // assign variables with test data String ex...
def player_rank(cls, player, date): try: P_RANKS = cls.RANKS[player] except KeyError: return False init_date = P_RANKS[0] if date < init_date: return False date_ind = DATES.day_diff(date, init_date) rank = P_RANKS[date_ind + 1] return rank
Former Massachusetts Gov. Mitt Romney is reportedly considering a Senate run in Utah if longtime Sen. Orrin Hatch retires. UtahPolicy.com reports that sources close to Mr. Romney say he’s making preparations to run, but some say Mr. Hatch likely won’t make a decision on whether he’ll run for another term until the end...
/** * Builds a creationTx from scriptPubKey and a spendingTx from scriptSig * such that spendingTx spends output zero of creationTx. * Also inserts creationTx's output into the coins view. */ void BuildTxs(CMutableTransaction& spendingTx, CCoinsViewCache& coins, CMutableTransaction& creationTx, const ...
Sebastian Vettel has stated he does not "understand" why Felipe Massa has struggled so much alongside Fernando Alonso at Ferrari. The 2012 championship looks set to be a head-to-head contest between Red Bull's Vettel and Ferrari number 1 Alonso. But with Ferrari still yet to sign up Alonso's teammate Felipe Massa for...
Home » forums » LtU Forum Virgil: a statically-typed language balancing functional and OO features In PLDI this year: Ben Titzer, "Harmonizing Classes, Functions, Tuples, and Type Parameters in Virgil III" [pdf] Given a fresh start, a new language designer is faced with a daunting array of potential features. Where to ...
import EventEmitter from "eventemitter3"; type MediaSessionEvents = { [key in MediaSessionAction]: (details: MediaSessionActionDetails) => void; }; function createMediaSessionHandler() { const actions: MediaSessionAction[] = [ "play", "pause", "seekbackward", "seekforward", ...
// // UILabel+adjustSize.h // LPDCrowdsource // // Created by 沈强 on 16/3/30. // Copyright © 2016年 elm. All rights reserved. // #import <UIKit/UIKit.h> NS_ASSUME_NONNULL_BEGIN typedef NS_ENUM(NSInteger,LPDAdjustAlignment) { LPDAdjustAlignmentLeft, LPDAdjustAlignmentRight, LPDAdjustAlignmentBottom, LPDAdju...
import { Action, ActionPanel, Form, Icon, LocalStorage, showToast, Toast, useNavigation } from "@raycast/api"; import React, { Dispatch, SetStateAction, useEffect, useState } from "react"; import { CountdownDate } from "./types/types"; import { LocalStorageKey } from "./utils/constants"; import Style = Toast.Style; imp...
def resolution(self, recalc=False): transform = self._cached_transform() if ( not recalc or self.width == 1 or self.height == 1 ) and transform is not None: return _resolution(transform) try: left, bottom, right, top = self._internal_bounds() e...
/** * @brief Update Gas Gouge characteristic * @param None * @retval tBleStatus Status */ tBleStatus GG_Update(uint32_t soc, uint32_t voltage, int32_t current) { tBleStatus ret; uint8_t buff[2+2+2+2+1]; #ifdef STM32_SENSORTILE current=current/10; #endif STORE_LE_16(buff ,(HAL_GetTick()>>3)); S...
/** * Validates the device info structure * * @param 1 PDeviceInfo - Device info struct. * * @return Status of the function call. */ STATUS validateDeviceInfo(PDeviceInfo pDeviceInfo) { STATUS retStatus = STATUS_SUCCESS; CHK(pDeviceInfo != NULL, STATUS_NULL_ARG); CHK(pDeviceInfo->version <= DEVI...
// HashAndSalt is used to hash and salt a string // it has to be already a byte tho func HashAndSalt(pwd []byte) string { hash, err := bcrypt.GenerateFromPassword(pwd, bcrypt.MinCost) if err != nil { log.Println(err) } return string(hash) }
-- This file has been generated by specsgen. Do not modify by hand! module Unison.Target.Minimal.SpecsGen.InstructionType (instructionType) where import Unison import Unison.Target.Minimal.SpecsGen.MinimalInstructionDecl instructionType i | i `elem` [B, Bif, Br] = BranchInstructionType | i `elem` [Load, Mov...
<reponame>shwinnn/jupyterlab-sql import datetime import uuid import decimal def make_row_serializable(row): return tuple(_make_value_serializable(value) for value in row) def _make_value_serializable(value): type_ = type(value) processor = DISPATCHER.get(type_) if processor is not None: retu...
def checkEnergyBalance(self, lyr, mesh): temperatureStartNode, temperatureEndNode, dirichletStartNode, dirichletEndNode = self.getNodeCounts(mesh, lyr) powerIn = 0 powerOut = 0 for n in range(temperatureStartNode, temperatureEndNode): powerIn = powerIn + self.b[n] for n in range(dirichletSt...
// EncodeLowerCamelCase encodes a slice of words into lowerCamelCase func EncodeLowerCamelCase(words DecodedIdentifier) string { if len(words) == 0 { return "" } b := strings.Builder{} b.Grow(aggregateStringLen(words)) b.WriteString(words[0]) for _, w := range words[1:] { b.WriteString(strings.Title(w)) } r...
<gh_stars>0 import { useEffect, useRef, useState } from "react"; import { EventData } from "../../nhlapi/schema"; import * as d3 from "d3"; import { RinkMap } from "./rink/rinkPlot"; import * as d3hex from "d3-hexbin"; import "./rink/rink-style.css"; import "./rink-vis.scss"; export function RinkChart({data}: {data...
package myapp.coreservlets; import java.io.* ; import org.jdom2.*; import org.jdom2.output.*; import org.jdom2.input.*; public class WriteXML { public static void main(String fileAbsolutePath) throws Exception { Element addresslist = new Element("addresslist") ; Element linkman = new Element("linkm...
/** * Read one file completely from the target file system. * * @param lfs * @param fs * @param buffer * @throws IOException */ private void readOneFile( Path path, FileSystem fs, byte[] buffer, int threadIndex, FileIoStats stats) throws IOException { LOG.debug("Thread {}: Rea...
<reponame>10xbeta/tb2s // Copyright 2018 <NAME>, <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 appli...
<gh_stars>0 import { Router, Request, Response, NextFunction } from 'express'; import multer from 'multer'; import conf from '../conf'; import path from 'path'; import md5 from 'md5'; import fs from 'fs'; import { deleteFile, getAllFiles } from '../services/fileService'; import { BadRequestError } from '../middlewares/...
/** * amdgpu_bo_create_kernel_at - create BO for kernel use at specific location * * @adev: amdgpu device object * @offset: offset of the BO * @size: size of the BO * @domain: where to place it * @bo_ptr: used to initialize BOs in structures * @cpu_addr: optional CPU address mapping * * Creates a kernel BO a...
/*------------------------------------------------------------------------ pid_calc DESCRIPTION Performs PID calculations for the _pid structure *a. This function uses the positional form of the pid equation, and incorporates an integral windup prevention algorithim. Rectangular integration is used, so th...
/* This file is part of Mino. * * See the NOTICE file distributed with this work for copyright information. * * 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.o...
def hack_server(self)->(bool,str): success = True if not self.leaked_pointer: success = success and self.get_stack_address()[0] return success and self.change_secret_key()[0]
House Budget Chairman Paul Ryan (R-WI) is facing criticism for his new budget proposal from an unexpected source: conservative policy wonks. Virtually all of them found something to like in his plan. But they voiced substantial critiques in three flavors: lament that the entitlement reforms don’t go far enough, argume...
def kostalData(url="http://192.168.1.99/index.fhtml",login='pvserver',pwd='pvwr'): try: response = html.fromstring(requests.get( url , auth = ( login, pwd )).content ) data = [v.text.strip() for v in response.xpath("//td[@bgcolor='#FFFFFF']")] kostal = { 'CurrentAC' : data[0], ...
// TODO: remove this method after implementing it along side the registered proofs and importing it from there. func SectorSizeForRegisteredProof(p abi.RegisteredProof) (abi.SectorSize, error) { switch p { case abi.RegisteredProof_StackedDRG32GiBSeal, abi.RegisteredProof_StackedDRG32GiBPoSt: return 32 << 30, nil c...
// Adds a copy of the given shape unless it is already present. // Returns the assigned index or index of existing shape if already present. int ShapeTable::AddShape(const Shape& other) { int index; for (index = 0; index < shape_table_.size() && !(other == *shape_table_[index]); ++index) continue; if (...
President Trump proposed this morning “a contest as to which of the Networks, plus CNN and not including Fox, is the most dishonest, corrupt and/or distorted in its political coverage”. We should have a contest as to which of the Networks, plus CNN and not including Fox, is the most dishonest, corrupt and/or distorted...
/** * Do a kind of end to end test with some real rules. */ public void testIntegrationWithSuccess() throws Exception { Scenario sc = new Scenario(); FactData[] facts = new FactData[]{new FactData( "Cheese", "c1", ...
The launch of Vostok on April 12, 1961. A declassified document offers new information on what happened during Gagarin’s flight. Declassified documents offer a new perspective on Yuri Gagarin’s flight As anyone who has done research on the topic knows, there’s an abundance of bewildering information about the Soviet s...
<gh_stars>0 import numpy as np import pandas as pd from . import stream2, generator, segmentor, synchronizer, processor, scheduler, pipeline, node from loguru import logger import sys from . import extensions as ext from . import mhealth_format as mh from .error_code import ErrorCode import tqdm class ClassSet: d...
def zip_and_separate(cls, as_feature: bool, *argv, separator: str = _sep + ' '): f = [] for tupl in argv: ky, vl = tupl s = [separator] * len(ky) if as_feature: f = f + [e for l...
// // UIVIew+Debug.h // // Created by 余洪江 on 16/03/01. // Copyright © MRJ. All rights reserved. // #import <UIKit/UIKit.h> #import <QuartzCore/QuartzCore.h> #import <objc/runtime.h> @interface UIView (Debug) @end
Photo by: LinkedIn University of Illinois computer-science graduate student and research assistant Shayan Tabe Bordbar's profile photo on LinkedIn. URBANA — A University of Illinois graduate student who was stranded in Iran by a new executive order on immigration may be making his way to campus this week, officials sa...
What I need from you is to know what you can do, you and your fellow non-communist colleagues in the lower House, what you can do to stop these communist tyrannical executive orders laid down by this foreign-born, America-hating communist despot? "Thank you for your question—he said it loud enough that you all heard i...
/* Return an elapsed time string from integer seconds INPUT : Long int measuring seconds OUTPUT : HH:MM:SS */ std::string Format::ElapsedTime(long seconds) { if (seconds < 0) seconds = 0; const int hh = seconds / 3600; const int mm = (seconds - hh*3600) / 60; const int ss = (seconds - hh*3600 -...
/* * ComplexNumber class represents a complex number and provides functions to * compute addition, multiplication and square magnitude of complex numbers. */ class ComplexNumber { public: ComplexNumber(double r = 0.0, double i = 0.0) : _r(r), _i(i) {} ComplexNumber(const ComplexNumber&) = default; ComplexNu...
<gh_stars>0 package cmd import ( "fmt" "io/ioutil" "net/http" "strings" ) type ClientAction struct { Type string `json:"type"` Payload interface{} `json:"payload"` } type DialogInfoPayload struct { Message string `json:"message"` URL string `json:"url"` } func echoDialogInfo(message string, url ...
<filename>db/problem_gen.go // Auto generated by gendb. DO NOT EDIT. package db import ( "errors" "fmt" "time" ) const ( ProblemSelectCols = "id, name, statement, score, is_flag, flag" ProblemTable = "problems" ) var ( ErrNotCreatedProblem = errors.New(`given problem is not created on database`) ) func (...
<reponame>ZooPhy/zoophy-services<gh_stars>1-10 package edu.asu.zoophy.rest.pipeline.utils; import org.springframework.http.HttpStatus; import org.springframework.web.bind.annotation.ResponseStatus; import edu.asu.zoophy.rest.pipeline.PipelineException; /** * Custom exception for Geoname Disjointer errors * @author...
def stop_all_pumps(): result = pump_api.LCP_StopAllPumps() qmixbus.throw_on_error(result)
import { BackButton, ButtonBar, DateField, DinaForm, DinaFormOnSubmit, FieldSet, ResourceSelectField, SelectField, SubmitButton, TextField, useApiClient, useQuery, withResponse } from "common-ui"; import { Field } from "formik"; import { keys } from "lodash"; import { NextRouter, useRouter } f...
import numpy as np import cv2 from .fill import fill, fill_ave_mask KERNEL = np.ones((5, 5), np.uint8) def simple_mask(im_lines): """ Compute polygon, bounding rect and rough mask based on lines from image. :return: poly, rect, mask """ _, thresh = cv2.threshold(255 - im_lines, 10, 255, 0) ...
A Proposal of Wide-Band Air-to-Ground Communication at Airports Employing 5-GHz Band Recently, the frequency resource for a future wide-band communication system in Air Traffic Control (ATC) at advanced airports has become a vital issue of aeronautical industry, many studies on new frequency bands coupled with high-bi...
def players_menu(): print('// Players Menu: ') print('1. Player search') print('0. Return to main menu')
class ValidatorResult: status = False message = '' rescue_commands = [] last_check_time = 'unknown' def __init__(self, status: bool, message: str, rescue_commands: list): self.status = status self.message = message self.rescue_commands = rescue_commands def is_ok(self...
// SuggestCommand create a ClickEvent replaces the content of the chat box with the given text - // usually a command, but it is not required to be a command // (commands should be prefixed with /). // This is only usable for messages in chat. func SuggestCommand(cmd string) *ClickEvent { return &ClickEvent{ Action:...
WikiLeaks has released another small glimpse into the major case they claim will end Hillary Clinton’s campaign and lead to her being charged criminally. Julian Assange has released 67 emails showing that Hillary Clinton communicated with someone using an alias. Now, Assange only released 67 emails for now, so it is m...
// Copyright (c) 2019, AT&T Intellectual Property. All rights reserved. // // Copyright (c) 2015-2016 by Brocade Communications Systems, Inc. // All rights reserved. // // SPDX-License-Identifier: MPL-2.0 package union import ( "github.com/danos/config/schema" "github.com/danos/utils/pathutil" ) // Return set of h...
N = int(input()) S = input() W = [0] * N W[-1] += S[-1] == "." for i in range(N - 2, -1, -1): W[i] = W[i + 1] + (S[i] == ".") B = [0] * N B[0] += S[0] == "#" for i in range(1, N): B[i] = B[i - 1] + (S[i] == "#") T = [w + b - 1 for w, b in zip(W, B)] T = min(T) print(min(T, W[0], B[-1]))
/* * Mark specified number of bits as "set". Cannot set all bits like ClearAll * since there might be unused bits - setting those to one will confuse the * iterator. */ void dvmSetInitialBits(BitVector* pBits, unsigned int numBits) { unsigned int idx; assert(((numBits + 31) >> 5) <= pBits->storageSize); ...
def non_dominated_sense_by_own_pieces(board): actions = [] for square in SENSE_SQUARES: rank = chess.square_rank(square) file = chess.square_file(square) if rank < 6: for offset in [-9, -8, -7]: piece = board.piece_at(square + offset) if piece ...
/** * The binder try to convert String values to Java objects. */ public abstract class Binder { private static final Logger logger = LoggerFactory.getLogger(Binder.class); public static final Object MISSING = new Object(); private static final Object DIRECTBINDING_NO_RESULT = new Object(); private s...
/** * <pre> * <h3 color="80d8ff">Overview</h3> * * Defines if this engine supports given language. Make sure to perform this check, otherwise * initializing an engine with an un-supported language may result to {@code null} engine. * * @param language Language to check if is suppo...
// Copyright 2015, VIXL authors // 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 notice, // this list of conditions ...
//! Subcommands for forge //! //! All subcommands should respect the `foundry_config::Config`. //! If a subcommand accepts values that are supported by the `Config`, then the subcommand should //! implement `figment::Provider` which allows the subcommand to override the config's defaults, see //! [`foundry_config::Conf...
def receiveCallback(self, socket, stateMask): strBuffer = self.recv(CCSDS.PACKET.PRIMARY_HEADER_BYTE_SIZE) if strBuffer == None: return packetHeader = array.array("B", strBuffer) packetHeaderLen = len(packetHeader) if packetHeaderLen != CCSDS.PACKET.PRIMARY_HEADER_BYTE_SIZE: LOG_ERROR("R...
/* * * Alt : * Defines the 'alt' attribute. * */ class Alt : public SingleValueAttribute<std::string> { public: Alt(); }
/** * <xs:complexType name="PayloadStructureType" abstract="true"> <xs:annotation> <xs:documentation>PayloadStructureType is an abstract base type used to define the structural information for data or metadata sets. A reference to the structure is provided (either explicitly or through a reference to a structure ...
# WINNERS OF THE $10,000 JOURNEY PRIZE 1989 Holley Rubinsky for "Rapid Transits" 1990 Cynthia Flood for "My Father Took a Cake to France" 1991 Yann Martel for "The Facts Behind the Helsinki Roccamatios" 1992 Rozena Maart for "No Rosa, No District Six" 1993 Gayla Reid for "Sister Doyle's Men" ...
Ellen Louise Axson Wilson (May 15, 1860 – August 6, 1914),[1] was the first wife of Woodrow Wilson and the mother of their three daughters. Like her husband, she was a Southerner, as well as the daughter of a clergyman. She was born in Savannah, Georgia, but raised in Rome, Georgia. Having an artistic bent, she studied...