content stringlengths 2 6.21k | label stringclasses 16
values |
|---|---|
));
}
/**
* Creates the layout of the panel (but the contents are not populated here).
*/
private void createLayout()
{
GridBagConstraints gbc = new GridBagConstraints();
CardLayout cardLayout = new CardLayout();
mainPanel = new JPanel(cardLayout);
mainPanel.setOpaque(false);
NoItemSe... | Java |
events_duration = {
[1] = 2.927188,
},
randomize_indexes = {},
},
mission_twins_exchange_02_e = {
randomize_indexes_n = 0,
sound_events_n = 1,
sound_events = {
[1] = "loc_interrogator_a__mission_twins_exchange_02_e_01",
},
sound_events_duration = {
[1] = 1.69125,
},
randomize_indexes = {},
... | Lua |
.bank.v1beta1.QueryDenomOwnersRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest
27, // 19: cosmos.bank.v1beta1.DenomOwner.balance:type_name -> cosmos.base.v1beta1.Coin
21, // 20: cosmos.bank.v1beta1.QueryDenomOwnersResponse.denom_owners:type_name -> cosmos.bank.v1beta1.DenomOwner
29, // 21: cosmo... | Go |
# 10.11.54.69
# as degrees.
# I can't find this definition in documentation anywhere, though.
unit = u.deg
if len(string_rep.split('.')) >= 3:
string_rep = string_rep.replace('.', ':', 2)
elif string_rep.count(':') == 2:
unit = u.hour
return An... | Python |
) -> Result<MsgQueueMergerIterator> {
MsgQueueMergerIterator::from_manager(self, shard)
}
/// find enquque message and return it with neighbor id
pub fn find_message(&self, key: &OutMsgQueueKey, prefix: &AccountIdPrefixFull) -> Result<(Option<BlockIdExt>, Option<MsgEnqueueStuff>)> {
for nb ... | Rust |
# PROVA AULA 05 Desenvolva um programa em Python para calcular a média de notas de alunos em uma disciplina. O programa deve solicitar ao usuário o número de alunos e, em seguida, para cada aluno, pedir o nome e três notas. Utilize um loop 'for' para iterar sobre os alunos e suas notas.
# Além disso, implemente uma es... | Python |
ore_country\") = UPPER('Gender') group by \"store\".\"store_country\" order by \"store\".\"store_country\" ASC",
"",
"select \"store\".\"store_type\" as \"c0\" from \"store\" as \"store\" where UPPER(\"store\".\"store_type\") = UPPER('Gender') group by \"store\".\"store_type\" order by \"store\".\"store_typ... | Java |
e.ID_MODULO);
// Ricezione Messaggio
msgDiag.mediumDebug("Ricezione richiesta (SbustamentoRisposteMessage)...");
ObjectMessage received = (ObjectMessage)message;
SbustamentoRisposteMessage sbustamentoRisposteMsg = null;
try{
sbustamentoRisposteMsg = (SbustamentoRisposteMessage)received.getObject()... | Java |
: {'content-type': 'application/json'},
);
var responseBody = resp.body;
Map<String, dynamic> response = json.decode(responseBody);
final dataList = response['data'];
if (dataList == null || !(dataList is List)) {
print(
"[PROFILE] Getting for $studentNumber: data list is null or no... | Dart |
_content_networking_system_software:$1/
match http-proxy m|^<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4\.01 Transitional//EN\" \"http://www\.w3\.org/TR/html4/loose\.dtd\">.*ERROR: The requested URL could not be retrieved|s p/Squid http proxy/ cpe:/a:squid-cache:squid/
match http-proxy m|^<!DOCTYPE HTML PUBLIC \"-//W3C/... | Go |
20101: '澳门半岛',
820201: '离岛'
}}
export const country = [
{ id: 1, en: "Afghanistan", zh: "阿富汗" },
{ id: 2, en: "Aland Islands", zh: "阿兰群岛" },
{ id: 3, en: "Albania", zh: "阿尔巴尼亚" },
{ id: 4, en: "Algeria", zh: "阿尔及利亚" },
{ id: 5, en: "American Samoa", zh: "美属萨摩亚" },
{ id: 6, e... | JavaScript |
-02"), fmt.Sprintf("%d", minPoint.idmin))
printer.Printf("Absolute max: %.2f, date %s, sensorID %s\n", maxPoint.max, maxPoint.date.Format("2006-01-02"), fmt.Sprintf("%d", maxPoint.idmax))
}
// Copyright (C) 2017 ScyllaDB
package backupspec
import (
"strings"
"testing"
"github.com/google/go-cmp/cmp"
"github.... | Go |
,
[3866877262] = "ch3_12_restccloth_01",
[437772318] = "ap1_01_b_line_03",
[3517801483] = "ch3_12_paddockfencei_hi",
[902852738] = "ch3_12_paddockfencec_hi",
[285744619] = "ch3_12_fizzrails08",
[426106918] = "cs5_4_q_3f_rail2",
[2823377275] = "ch3_12_fur_mask_18",
[1896506110] = "ch3_12_fur_mask_13",
[20018864... | Lua |
6V20C5 20.2652 5.10536 20.5196 5.29289 20.7071C5.48043 20.8946 5.73478 21 6 21H18C18.2652 21 18.5196 20.8946 18.7071 20.7071C18.8946 20.5196 19 20.2652 19 20V6C19 5.73478 18.8946 5.48043 18.7071 5.29289C18.5196 5.10536 18.2652 5 18 5H16C15.4477 5 15 4.55228 15 4C15 3.44772 15.4477 3 16 3H18C18.7956 3 19.5587 3.31607 2... | CSS |
rder-radius: 5px;
padding-left: 10px;
padding-right: 10px;
padding-top: 10px;
padding-bottom: 10px;
}
QCheckBox {
background-color: transparent; /* Transparent background for checkboxes */
}
... | Python |
42 49.45,29.64
path 50.03,27.63 50.56,26.44 49.98,23.97 47.47,22.67 46.33,24.57
path 44.74,25.50 43.42,26.50 40.87,28.82 40.14,32.21 38.73,33.10
path 36.97,34.22 36.66,38.10 36.42,41.03 34.95,40.76 33.81,39.53
path 31.73,42.03 30.29,43.54 28.79,44.84 28.04,47.89 27.69,50.35
path 29.34,52.92 29.92,54.14 31.79,52.55
Clic... | Lua |
creen and (min-width:768px){#tag-heading{padding:55px 0}}#tag_cloud{margin:20px 0 15px 0}#tag_cloud .tag,#tag_cloud a{font-size:14px;border:none;line-height:28px;margin:0 2px;margin-bottom:8px;background:#D6D6D6}#tag_cloud .tag:active,#tag_cloud .tag:hover,#tag_cloud a:active,#tag_cloud a:hover{background-color:#0085a1... | CSS |
is {mode}, Current pop size: {pop_size}\033[0m")
print(f"\033[91mTotal cost: {end - start}\033[0m")
torch.cuda.empty_cache()
if __name__ == "__main__":
from gapa.utils.init_device import init_device
device, world_size = init_device(world_size=2)
# device, _ = mutil_init_device(world_size=2)
im... | Python |
# ========= Copyright 2023-2024 @ CAMEL-AI.org. 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 requ... | Python |
#ifndef __x_preset_h_
#define __x_preset_h_
/*
Global preset system by Ivica Ico Bukvic <ico@vt.edu> July, 2012
*/
#include "s_stuff.h"
// each node in the patch
typedef struct _preset_node
{
t_object pn_obj;
t_alist pn_val; // last known value (null if not initialized)
t_atom *pn_hub_name; // hub name th... | C |
toLowerCase() == 'false') {
print('[_parseGherkinValue DEBUG] Parsed as bool false');
return false;
}
if (valueToParse == "null") {
print('[_parseGherkinValue DEBUG] Parsed as null');
return null;
}
final intValue = int.tryParse(valueToParse);
print(
'[_parseGherkinValue DEBUG] int.tryPa... | Dart |
ad` 函数也非常有趣,它返回一个 `!` 类型,这个表明该函数是一个发散函数,不会返回任何值,包括 `()`。`unimplemented!()` 告诉编译器该函数尚未实现,`unimplemented!()` 标记通常意味着我们期望快速完成主要代码,回头再通过搜索这些标记来完成次要代码,类似的标记还有 `todo!()`,当代码执行到这种未实现的地方时,程序会直接报错。你可以反注释 `read(&mut f1, &mut vec![]);` 这行,然后再观察下结果。
同时,从代码设计角度来看,关于文件操作的类型和函数应该组织在一起,散落得到处都是,是难以管理和使用的。而且通过 `open(&mut f1)` 进行调用,也远没有... | Markdown |
title: 'ข้อความ',
confirm: 'ตกลง',
cancel: 'ยกเลิก',
error: 'คุณป้อนข้อมูลไม่ถูกต้อง'
},
upload: {
deleteTip: 'กดปุ่ม "ลบ" เพื่อลบออก',
delete: 'ลบ',
preview: 'ตัวอย่าง',
continue: 'ทำต่อ'
},
table: {
emptyText: 'ไม่พบข้อมูล',
confirmFilter: 'ย... | JavaScript |
(t, len(l) == 3, "expected len(l) == 3, got:", len(l))
e = MarkPendingOperationsStale(tx)
tests.Assert(t, e == nil, "expected e == nil, got", e)
return nil
})
oc := OperationCleaner{
db: app.db,
executor: app.executor,
sel: CleanAll,
}
e = oc.Clean()
tests.Assert(t, e == nil, "expected e ==... | Go |
**************************/
/* CTX menu */
/**************************/
.flowrun-context-menu {
display: none;
}
.flowrun-context-menu.active {
position: absolute;
/* relative to the BODY! so it stays there always.. */
z-index: 10000;
width: 150px;
display: flex;
flex-direction: column;
... | CSS |
has(0);
@$pb.TagNumber(1)
void clearCode() => clearField(1);
@$pb.TagNumber(2)
$core.String get reason => $_getSZ(1);
@$pb.TagNumber(2)
set reason($core.String v) {
$_setString(1, v);
}
@$pb.TagNumber(2)
$core.bool hasReason() => $_has(1);
@$pb.TagNumber(2)
void clearReason() => clearField(2... | Dart |
* File modified by Appmattus Limited
* See: https://github.com/appmattus/certificatetransparency/compare/e3d469df9be35bcbf0f564d32ca74af4e5ca4ae5...main
*/
package com.appmattus.certificatetransparency.utils
import com.appmattus.certificatetransparency.datasource.DataSource
import com.appmattus.certificatetranspa... | Kotlin |
--videoinput: cross-platform video capturing library.
--Written by Cosmin Apreutesei. Public Domain.
local ffi = require'ffi'
local glue = require'glue'
local M = {}
local backends = {
osx = 'videoinput_cocoa',
linux = 'videoinput_v4l',
windows = 'videoinput_dshow',
}
local B = require(assert(backends[ffi.os:low... | Lua |
("|| |-||| ");
table.set_header(vec![
"".to_string(),
"M=10".to_string(),
"M=100".to_string(),
"M=1000".to_string(),
]);
for &l in &[10, 100, 1000] {
let mut row = vec![format!("L={}", l)];
for &m in &[10, 100, 1000] {
if l == 1000 && m ... | Rust |
感兴趣可以看makecookie命令源码。
> 作者创建rs-reverse项目的初衷是为了研究瑞数的加密与反爬原理,通过逆向方式促进技术进步,让对瑞数感兴趣的同学更方便的做研究。作者不建议直接将该项目应用于产线数据采集项目中,由此产生的任何后果与作者无关!!!
>
> 作者声明
该版本为cookie可用版本,感兴趣的同学可在下次瑞数更新前对比研究。
有任何问题欢迎提issues!> 本文由 [简悦 SimpRead](http://ksria.com/simpread/) 转码, 原文地址 [mp.weixin.qq.com](https://mp.weixin.qq.com/s/jgqGJ11dTbOiBBfebv_40... | Markdown |
relativi #2 (~)",
"pl": "Referencje względne #2 (~)",
"ta_IN": "இணைக்கப்பட்ட குறிப்பு #2 (~)",
"tr_TR": "Göreli Referanslar #2 (~)"
},
"startDialog": {
"en_US": {
"childViews": [
{
"type": "ModalAlert",
"options": {
"markdowns": [
"### The... | JavaScript |
r = 0x0D
Escape = 0x1B
Space = 0x20
Tab = 0x09
Backspace = 0x08
Delete = 0x2E
Insert = 0x2D
Home = 0x24
End = 0x23
PageUp = 0x21
PageDown = 0x22
# Arrow keys
LeftArrow = 0x25
UpArrow = 0x26
RightArrow = 0x27
DownArrow = 0x28
# Numpad keys
Numpad0 = 0... | Python |
)` | Глобальная настройка фраз для всех игроков. |
| `disableGlobal()` | Отключает все фразы глобально. |
| `setOnPlayerPhrase(handler)` | Устанавливает обработчик выбора фразы игроком. |
---
## 🎨 Класс `Phrase`
Описывает отдельную фразу.
### Конструктор:
```java
new Phrase("test1", "Текст фразы");
```
### 📦 По... | Markdown |
}
}
private fun gzip(body: RequestBody): RequestBody {
return object : RequestBody() {
override fun contentType(): MediaType {
return body.contentType()
}
override fun contentLength(): Long {
return -1 // We don't know the comp... | Kotlin |
GC thread is working (true)
pthread_t m_GCThread;
#ifndef WIN32
static void* garbageCollect(void*);
#else
static DWORD WINAPI garbageCollect(LPVOID);
#endif
std::map<UDTSOCKET, CUDTSocket*> m_ClosedSockets; // temporarily store closed sockets
void checkBrokenSockets();
void remove... | C |
/// let client = NacosClient::new(
/// &nacos,
/// ServerConfig::new("127.0.0.1", 8080, "test"),
/// );
///
/// // register current instance to nacos
/// // and new thread in background send and ack hart beat
/// client.register(&None).await;
/// ```
pub async fn register... | Rust |
'🥪',
'サンドイッチ | パン',
),
Emoji(
'🌮',
'タコス | メキシカン | メキシコ料理',
),
Emoji(
'🌯',
'ソフトタコス | ブリトー | メキシカン | メキシコ料理 | ラップサンド',
),
Emoji(
'🥙',
'ケバブ | ケバブサンド | ピタパン | ラップサンド',
),
Emoji(
'🍳',
'フライパン | レストラン | 卵 | 料理 | 朝食 | 目玉焼き',
),
... | Dart |
yPayload(TlvStream(OnionPaymentPayloadTlv.AmountToForward(561.msat), OnionPaymentPayloadTlv.OutgoingCltv(CltvExpiry(42)), OnionPaymentPayloadTlv.OutgoingNodeId(nodeId)))
val bin = Hex.decode("2e 02020231 04012a fe000102322102eec7245d6b7d2ccb30380bfbe2a3648cd7a942653f5aa340edcea1f283686619")
val decoded... | Kotlin |
ct(),
disabled: false,
}
}
}
#[derive(Debug, Serialize)]
pub struct WireConfig {
#[serde(rename = "core.themes")]
themes: Vec<String>,
}
impl Themeable for Atom {
fn config_state(&self, config: &ThconConfig) -> ConfigState {
ConfigState::with_default_config(config.atom.as_r... | Rust |
rt com.datastax.oss.dsbulk.tests.ccm.annotations.CCMConfig;
import com.datastax.oss.dsbulk.tests.ccm.annotations.CCMRequirements;
import com.datastax.oss.dsbulk.tests.ccm.annotations.CCMVersionRequirement;
import com.datastax.oss.dsbulk.tests.ccm.annotations.CCMWorkload;
import com.datastax.oss.dsbulk.tests.driver.anno... | Java |
[3540] = {"할 맥알리스터","생선 상인"},
[3541] = {"사라 레이크로프트","일용품 상인"},
[3542] = {"제이신 라니다","마법 재료 및 독극물 상인"},
[3543] = {"로버트 에비스처","고급 방어구 제작자"},
[3544] = {"제이슨 레미욱스","버섯 상인"},
[3545] = {"클라우드 에르크신","야수 조련사"},
[3546] = {"베르니 하이스텐","식료품 상인"},
[3547] = {"함린 아트킨스","버섯 상인"},
[3548] = {"셀리나 웨스톤","연금술용품 상인"},
[3549] = {"셸렌 로버트","전문 ... | Lua |
Y KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.youku.service.acc;
import java.io.File;
import android.content.Context;
import android.content.Intent;
import android.os.Build;
import android.os.Environment;
im... | Java |
File{Path: relpath}
type segment struct {
location Location
count int
covered bool
}
numSegements := u32()
segments := make([]segment, numSegements)
for j := range segments {
segment := &segments[j]
segment.location.Line = int(u32())
segment.location.Column = int(u32())
segment.cou... | Go |
padding: 4px !important;/* stylelint-disable-line declaration-no-important */
}
}
.e-bigger .e-pv-formfield-textcolor-icon {
@if ($skin-name=='tailwind3') {
height: 36px;
}
}
.e-bigger .e-pv-default-tab .e-pv-formfield-textcolor-icon {
@if ($skin-name=='tailwind3') {
padding: 0;
... | CSS |
_align=(int)go_bin.get_address_value(type_base_addr, offset+pointer_size*2+4+1*2, 1);
int kind_value=(int)go_bin.get_address_value(type_base_addr, offset+pointer_size*2+4+1*3, 1)&0x1f;
equal=go_bin.get_address_value(type_base_addr, offset+pointer_size*2+4+1*4, pointer_size);
gcdata=go_bin.get_address_value(type_b... | Java |
Progress == 100) {
progressBar.visibility = ProgressBar.GONE
}*/
}
}
}
private fun handlePullToRefresh() {
}
private fun handleOnKeyDown() {
live_view.canGoBack()
live_view.setOnKeyListener(View.OnKeyListener { v, keyCode,... | Kotlin |
y dir with busybox binary, an run.
#!/bin/sh
test -x busybox || { echo "No ./busybox?"; exit; }
ln -sf busybox uudecode
ln -sf busybox uuencode
>A_null
echo -n A >A
echo -n AB >AB
echo -n ABC >ABC
echo -n ABCD >ABCD
echo -n ABCDE >ABCDE
echo -n ABCDEF >ABCDEF
cat busybox >A_bbox
for f in A*; do
echo uuencode $f
... | C |
プラグインとしても利用できる。
これは利用をより簡単で実用的にするためである。
大きなファイルを大きなファイルに変換するようなトランスパイラでは、どのような最適化が行われたのかが分かりにくい。
一方で小さなコード片を小さなコード片に書き換える IDE の機能であれば、どのような最適化が行われたのかが分かりやすく、ユーザにとってより制御しやすい。
### 入力言語には主に Python を用いる
以下の 2 点を理由として、入力言語には Python のサブセットを用いる。
1. 利用しやすい: 学習しやすく、書きやすい。Python は広く普及していてかつそこそこ高級な言語である
2. 開発しやすい: 言語機能を制限すれ... | Markdown |
log.info("changing mode of %s from %o to %o", file, oldmode, newmode)
os.chmod(file, newmode)
@staticmethod
def _validate_shebang(shebang, encoding):
# Python parser starts to read a script using UTF-8 until
# it gets a #coding:xxx cookie. The shebang has to be the
# f... | Python |
.text{color: #999; font-size: 18px; position: absolute; left: 50%; margin-left: -27px; top: 55%;}
.app .page-navigator .template-item img{width: 100%;}
.app .page-navigator .add-blank-page{width:100px; height:45px; line-height:45px; text-align: center; background: #428BCA; color:#fff; font-size:40px; z-index:101; posi... | CSS |
-- Positions must be a table (or metatable) where table.x and table.y are accessible.
local FindVector = require( "features.pathfinder.find_vector" )
local Heap = require( "features.pathfinder.heap" )
local Luafinding = {}
Luafinding.__index = Luafinding
-- This instantiates a new Luafinding class for usage later.
-... | Lua |
.user.id,
},
)
self.assertEqual(response.status_code, 302)
self.assertEqual(Post.objects.last().title, "New title")
self.assertEqual(Post.objects.last().body, "New text")
def test_post_updateview(self):
response = self.client.post(
reverse("post_edit", args="1"),
{
... | Markdown |
metadata = dict(llm.metadata)
metadata["llm_classname"] = llm.class_name()
metadata["duration"] = duration
result = IdentifyWBSTaskDependencies(
query=query,
response=json_response,
metadata=metadata
)
return result
def raw_resp... | Python |
amageAmount() {
return this.damageSrc == DamageSource.outOfWorld ? Float.MAX_VALUE : this.fallDistance;
}
}
package net.minecraft.entity.ai;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityCreature;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.pathfinding.PathEnt... | Java |
td>[2, 15] (0.1)</td>
<td>4.</td>
<td></td>
</tr>
<tr>
<td><strong id="MPC_Z_V_AUTO_DN">MPC_Z_V_AUTO_DN</strong> (FLOAT)</td>
<td>Descent velocity in autonomous modes <p><strong>Comment:</strong> For manual modes and offboard, see MPC_Z_VEL_MAX_DN</p> </td>
<td>[0.5, 4] (0.5)</td>
<td>1.5</td>
<td>m/s</td>
</t... | Markdown |
new, empty, mutable value.
func (x *fastReflection_PartialUpgrade) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "inference.inference.PartialUpgrade.height":
return protoreflect.ValueOfUint64(uint64(0))
case "inference.inference.PartialUpgrade.node_version":
return p... | Go |
:c_void;
}
extern "C" {
pub fn malloc_usable_size(__ptr: *const ::std::os::raw::c_void) -> size_t;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct mallinfo {
pub arena: size_t,
pub ordblks: size_t,
pub smblks: size_t,
pub hblks: size_t,
pub hblkhd: size_t,
pub usmblks: size_t,
pub ... | Rust |
structive-foreground: 0 0% 98.04%;
--border: 218.18 26.83% 91.96%;
--input: 218.18 26.83% 91.96%;
--ring: 240 5.03% 64.9%;
--radius: 0.5rem;
}
.dark {
--background: 240 5.88% 10%;
--foreground: 0 0% 98.04%;
--card: 240 5.15% 19.02%;
--card-foreground: 0 0% 98.04%;
--popover: 220... | CSS |
掘|在数据挖掘中,如何通过聚类分析来发现规律?|
|情感分析|如何使用情感分析来分析一段文字中的情感倾向?|
|文本分类|基于深度学习的文本分类方法有哪些?|
|知识图谱|知识图谱和传统数据库有什么区别?|
|语音识别|语音识别中常用的特征提取算法有哪些?|
|图像识别|卷积神经网络在图像识别中的作用是什么?|
|生成对抗网络|生成对抗网络的目标是什么,它如何实现?|
| 分类 | 这个电脑游戏是属于哪种类型的? |
| 时间 | 这个事件发生的具体时间是什么时候? |
| 比较 | 相比其他品牌,这种汽车有哪些优点? |
| 描述 | 请描述一下你最喜欢的餐厅的氛围和菜品口感。 |
| 定位 | 在地图上指示出位于某个城市中心的最... | Markdown |
rviews-ad, #paidlistingAds, .min_navi_ad, object[width=\"340\"][height=\"170\"], #gg_ad, #joead, .advertorial_red { display: none!important; }\n.blockAd, .ad160_l, .ad160_r, .widePageAd, .gdgt-header-advertisement, .adv-lb, #header_leaderboard_ad_container, .adImgIM, .homepage__ad--top-leader-board, .hideIfEmptyAd, #bo... | JavaScript |
child:
//时间
Row(
children: <Widget>[
Text(
"日期:",
style: TextStyle(fontSize: 16),
),
Expanded(
child: Text(
selectedDate,
style:... | Dart |
extDocument/completion",
ReqParams: fmt.Sprintf(`{
"textDocument": {
"uri": "%s/main.tf"
},
"position": {
"character": 17,
"line": 10
}
}`, tmpDir.URI)}, `{
"jsonrpc": "2.0",
"id": 5,
"result": {
"isIncomplete": false,
"items": [
{
"label": "module.alpha",
"... | Go |
#ifndef SCOPEGUARD_H
#define SCOPEGUARD_H
// Taken from "Declarative Control Flow" (CppCon 2015)
// adjusted to work with Visual C++ 2013
#include <exception>
#include <utility>
#if defined(_MSC_VER) && (_MSC_VER < 1900)
#define noexcept
#endif
#include "UncaughtExceptions.h"
#if defined(_MSC_VER) && (_MSC_VER < 1900... | C |
get update
sudo apt-get install -y ca-certificates curl gnupg
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
NODE_MAJOR=20
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/nod... | Markdown |
-storage"
"github.com/flant/shell-operator/pkg/task"
)
const MainQueueName = "main"
// queueStorage is a thread-safe storage for task queues with basic Get/Set/Delete operations
type queueStorage struct {
mu sync.RWMutex
queues map[string]*TaskQueue
}
func newQueueStorage() *queueStorage {
return &queueStor... | Go |
json",
"tower2.json",
"tower3.json",
"tower4.json",
"tower5.json",
"tower6.json"
);
towerData = towerNames.stream()
.map(name -> getAssetLoader().loadJSON("towers/" + name, TowerData.class).get())
... | Java |
dBehaviour.setSelected(true);
hasSkyLight.setSelected(true);
hasRaids.setSelected(true);
infiniburnTag.setText("minecraft:infiniburn_overworld");
}
ambientLight.setPreferredSize(new java.awt.Dimension(-1, 36));
useCustomEffects.setOpaque(false);
useCustomEffects.addActionListener(e -> updateDimensionE... | Java |
RunStatusQueued,
WorkflowRunStatusRequested,
WorkflowRunStatusWaiting,
}
}
// MarshalText implements encoding.TextMarshaler.
func (s WorkflowRunStatus) MarshalText() ([]byte, error) {
switch s {
case WorkflowRunStatusCompleted:
return []byte(s), nil
case WorkflowRunStatusActionRequired:
return []byte(s), n... | Go |
import unittest
import pytest
from typing import NamedTuple, Optional
from .template import (
sd_version,
StableDiffusionVersion,
is_full_coverage,
APITestTemplate,
living_room_img,
general_negative_prompt,
)
base_prompt = "A modern living room"
general_depth_modules = [
"depth",
"dep... | Python |
: %v", "FPDFImageObj_LoadJpegFileInline", panicError)
}
}()
return i.pdfium.FPDFImageObj_LoadJpegFileInline(request)
}
func (i *pdfiumInstance) FPDFImageObj_SetBitmap(request *requests.FPDFImageObj_SetBitmap) (resp *responses.FPDFImageObj_SetBitmap, err error) {
if i.closed {
return nil, errors.New("instance i... | Go |
YNgZ7
4tI5xMNQ2WCqsQY5CJxMxo77FGTO6Nwax9ncAZ7FsOSQeMEUiATgqzJbzaohpc2S
pQjPBjAMp+M+L1iGz2M5swOGc+6SVNGljRSuCUfJiocy6MV4puUvClyBOXptNCQR
Gazd0mzlh5jwq+soiloCgaLJWYL/tMdZSCfHDw88T8LlyvzwnPgABzL15+ec0tpf
oaEu2zECgYEA42C28+7K78wMk5kCfpSJFYp3aMu560L5cK1cIouMwGVKd+h9DLxo
PLBzqxZB3AaJUMwNtVbi0mEqT/+WhzXjRflcVwmVEbGHXkTnZLXRPz... | Go |
ncId"
dao.insert(CredentialsSyncMetadataEntity(syncId = syncId, localId = loginId, deleted_at = "2023-07-21T20:21:40.552Z", null))
val result = testee.getRemovedEntitiesSince("2023-07-21T20:21:39.000Z")
assertEquals(1, result.size)
assertEquals(loginId, result[0].localId)
asser... | Kotlin |
gions = {
}
-- 触发器
triggers = {
}
-- 变量
variables = {
}
--================================================================
--
-- 初始化配置
--
--================================================================
-- 初始化时创建
init_config = {
suite = 1,
end_suite = 0,
rand_suite = false
}
--==============================... | Lua |
u := range args {
u = strings.ToLower(u)
r := simpleRule{t: urlMatch, content: u}
a.URLs.AddRule(r)
a.URLTags[r] = append(a.URLTags[r], acl)
}
case "user-agent":
exp := strings.Join(args, " ")
r, err := regexp.Compile("(?i)" + exp)
if err != nil {
return err
}
a.UserAgents = append(a.UserA... | Go |
NARY_MODE_CAPTURE_PP ? 2 : 1)
/* It is preferred to have not more than 2x scaling at one step
* in GDC (assumption is for capture_pp and yuv_scale stages) */
#define MAX_PREFERRED_YUV_DS_PER_STEP 2
/* Rules for computing the internal width. This is extremely complicated
* and definitely needs to be commented and ex... | C |
ollbar(
thickness: kScrollbarThickness,
thumbColor: Colors.grey,
controller: vertical,
thumbVisibility: false,
trackVisibility: false,
child: widget,
);
}
return Container(
child: widget,
width: layoutSize.width,
height: layoutSize.height,... | Dart |
ng = true,
flashout = {
dur = 1,
black = true,
alpha = {
0,
1
}
},
flashin = {
delay = 1,
dur = 1,
black = true,
alpha = {
1,
0
}
},
typewriter = {
speed = 0.05,
speedUp = 0.01
},
painting = {
alpha = 0.3,
time = 1
}
}
}
... | Lua |
Value: float64(rand.Intn(150))},
{Name: "内蒙古", Value: float64(rand.Intn(150))},
}
guangdongMapData = map[string]float64{
"深圳市": float64(rand.Intn(150)),
"广州市": float64(rand.Intn(150)),
"湛江市": float64(rand.Intn(150)),
"汕头市": float64(rand.Intn(150)),
"东莞市": float64(rand.Intn(150)),
"佛山市": float64(rand.I... | Go |
(prefers-reduced-motion:reduce){.form-select{transition:none}}.form-select:focus{border-color:rgba(121,135,161,.4);outline:0;box-shadow:var(--bs-box-shadow-inset),0 0 0 0 rgba(101,113,255,.25)}.form-select[multiple],.form-select[size]:not([size="1"]){padding-right:.8rem;background-image:none}.form-select:disabled{back... | CSS |
uYW1lIjoiRXhhbXBsZSBWQyIsImxvY2FsZSI6ImVuIiwibG9nbyI6eyJ1cmwiOiJodHRwczovL2V4YW1wbGUub3JnL2xvZ28ucG5nIiwiYWx0X3RleHQiOiJleGFtcGxlIGxvZ28ifSwiZGVzY3JpcHRpb24iOiJNeSBleGFtcGxlIGNyZWRlbnRpYWwiLCJjdXN0b21QYXJhbWV0ZXJzIjp7ImJhY2tncm91bmRDb2xvciI6IiMwMDAwMDAiLCJ0ZXh0Q29sb3IiOiIjRkZGRkZGIn19XSwiX3NkIjpbIjNQMnJpUVNUSDZLM0g1N1g... | Kotlin |
ed to track IronMon attempts.
> \* mGBA's lua scripting is currently limited and doesn't provide any drawing functionality, this means the tracker on mGBA is purely text-based in the scripting window as we can't draw images/screens like on Bizhawk.
For more information on IronMon, see <http://ironmon.gg>
We have a se... | Markdown |
general queue which can accepts different dialog type.
///
/// [Visibility]
/// The `_FileDialogType` and `_DialogEvent` are invisible for other models.
enum FileDialogType { overwrite, unknown }
class _FileDialogEvent extends BaseEvent<FileDialogType, Map<String, dynamic>> {
WeakReference<FileModel> fileModel;
b... | Dart |
list_memory.data + list_ref;
}
bool remove_iterator_done(const remove_iterator_t* it) {
const ivector_t* current_list;
current_list = watch_list_manager_get_list_of_lists(it->wlm, it->watcher);
return current_list == NULL || it->current >= current_list->size;
}
void remove_iterator_next_and_keep(remove_iterator... | C |
64, emptyList()),
LayerSummary("maxPool_2", "MaxPool2D", TensorShape(-1, 7, 7, 64), 0, emptyList()),
LayerSummary("flatten_1", "Flatten", TensorShape(-1, 3136), 0, emptyList()),
LayerSummary("dense_1", "Dense", TensorShape(-1, 512), 1606144, emptyL... | Kotlin |
T702xx-2|ST80208|ST97216|ST70104-2|VT10416-2|ST10216-2A|SurfTab`,
// @ref: http://www.pyleaudio.com/Products.aspx?%2fproducts%2fPersonal-Electronics%2fTablets
//PYLEAUDIOTABLET:
`\b(PTBL10CEU|PTBL10C|PTBL72BC|PTBL72BCEU|PTBL7CEU|PTBL7C|PTBL92BC|PTBL92BCEU|PTBL9CEU|PTBL9CUK|PTBL9C)\b`,
// @ref: http://www.advand... | Go |
-> controlInstructionDecoder(context).bind()
PREFIXED_OPCODES.contains(opcode) -> prefixInstructionDecoder(context).bind()
else -> Err(InstructionDecodeError.UnknownInstruction(opcode)).bind<Instruction>()
}
}
private fun Set<UIntRange>.contains(opcode: UByte): Boolean = any { range ->
range.... | Kotlin |
#python program that prints a pyramid pattern with a given height
def print_pyramid(height):
for i in range(1, height + 1):
print(" " * (height - i) + "*" * (2* i - 1))
pyramid_height = int(input("Enter the height of the pyramid: "))
print_pyramid(pyramid_height)
| Python |
(value != null) {
return ValueExpression(value);
}
return fallback != null ? ValueExpression(fallback) : null;
}
bool? safeParseBool(Object? source) {
if (source is bool) {
return source;
} else if (source is int) {
switch (source) {
case 1:
return true;
case 0:
return... | Dart |
}
}
}
func BenchmarkFindAddTarget(b *testing.B) {
n := 500
d := simpleTDigest(n)
b.ResetTimer()
var val float64
for i := int64(0); i < int64(b.N); i++ {
val = float64(i % d.countTotal)
_ = d.findAddTarget(val)
}
}
// add the values [0,n) to a centroid set, equal weights
func simpleTDigest(n int) *TDige... | Go |
949 0 0 1-5.895 5.123h-40.156c.12-.203.24-.398.353-.608A23.85 23.85 0 0 0 144 180c0-13.26-10.747-24-24-24s-24 10.74-24 24c0 4.26 1.11 8.265 3.06 11.73.112.21.233.405.352.608H62.167a5.96 5.96 0 0 1-5.895-5.123l-2.474-17.535-7.425-52.553-.893-6.307-.322-2.325-.098-.667c-.503-3.585 2.273-6.788 5.895-6.788H87.57a5.947 5.94... | CSS |
import numpy as np
import minari
import cv2
# 1) load the expert AdroitHandDoor dataset
dataset = minari.load_dataset("D4RL/door/expert-v2")
# grab the first full episode
episode = next(dataset.iterate_episodes())
obs = episode.observations # shape (T+1, 39), float64
acts = episode.actions # shape (T, ... | Python |
"], 0));
(Ext.cmd.derive("Ext.util.Sortable", Ext.Base, {
isSortable : true,
defaultSortDirection : "ASC",
statics : {
createComparator : function(a) {
return a && a.length ? function(d, c) {
var b = a[0].sort(d, c), g = a.length, e = 1;
for (; e < g; e++) {
b = b || a[e].sort.call(... | JavaScript |
#!/usr/bin/env python3
"""
🚀 GHOST KITTY AUDIO CONVERTER - MEGA ENHANCEMENT INSTALLER 🚀
This script will install all the cool new features and dependencies!
"""
import subprocess
import sys
import os
import platform
from pathlib import Path
def print_banner():
"""Print cool installation banner"""
banner = "... | Python |
group--error{color:#c00}.tox .tox-form__group--collection{display:flex}.tox .tox-form__grid{display:flex;flex-direction:row;flex-wrap:wrap;justify-content:space-between}.tox .tox-form__grid--2col>.tox-form__group{width:calc(50% - (8px / 2))}.tox .tox-form__grid--3col>.tox-form__group{width:calc(100% / 3 - (8px / 2))}.t... | CSS |
w := httptest.NewRecorder()
// Run the benchmark
b.ReportAllocs()
b.ResetTimer()
for i := 0; i < b.N; i++ {
err := waf.Analyze(w, r)
if err != nil {
b.Fatal(err)
}
}
}
func BenchmarkAnalyzeWithoutCommonWebAttack(b *testing.B) {
// Initialize teler
waf := New(Options{
Excludes: []threat.Threat{
... | Go |
--[[
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
]]--
local ... | Lua |
(dbg)
if err != nil {
panic(err)
}
tm.main = main
hook, err := dbg.AddControl(func(ctx debugger.Context, data any) { main.Close() }, nil)
if err != nil {
panic(err)
}
main.appendRelease(hook.Close)
main.reset(context.TODO(), dbg)
tm.current = main
addr := hook.Addr()
go func() {
stopped := make(chan st... | Go |
_CHARACTERS}</th>
* <th>{@link #PARSE_MULTIPLE_CONTEXT}</th>
* </tr>
* <tr><td>STRICT</td><td>false</td><td>false</td><td>false</td><td>false</td></tr>
* <tr><td>SMART</td><td>true</td><td>false</td><td>false</td><td>true</td></tr>
* <tr><td>LAX</td><td>true</td><td>true</td><td>true</... | Java |
�ത്ഥവും, ഉത്തമമായ ആഹാരവും നിങ്ങളുണ്ടാക്കുന്നു. ചിന്തിക്കുന്ന ജനങ്ങള്ക്ക് തീര്ച്ചയായും അതില് ദൃഷ്ടാന്തമുണ്ട്."
},
{
"surah_number": 16,
"verse_number": 68,
"content":
"നിന്റെ നാഥന് തേനീച്ചയ്ക്ക് ഇപ്രകാരം ബോധനം നല്കുകയും ചെയ്തിരിക്കുന്നു: മലകളിലും മരങ്ങളിലും മനുഷ്യര് കെട്ടിയുയര്ത്തുന്നവയി... | Dart |
rackEnded<Self> {
OnStreamTrackEnded::new(self.inner.as_ref())
}
pub fn on_track_mute(&self) -> OnStreamTrackMute<Self> {
OnStreamTrackMute::new(self.inner.as_ref())
}
pub fn on_track_unmute(&self) -> OnStreamTrackUnmute<Self> {
OnStreamTrackUnmute::new(self.inner.as_ref())
... | Rust |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.