content
stringlengths
2
6.21k
label
stringclasses
16 values
java.io.File; import sun.net.www.ParseUtil; /** * (Solaris) platform specific handling for file: URLs . * urls must not contain a hostname in the authority field * other than "localhost". * * This implementation could be updated to map such URLs * on to /net/host/... * * @author Michael McMahon */ publ...
Java
hMap<String, String> escapeJavaMap = new HashMap<String, String>(); escapeJavaMap.put("\"", "\\\""); escapeJavaMap.put("\\", "\\\\"); ESCAPE_JAVA = new AggregateTranslator(new LookupTranslator(Collections.unmodifiableMap(escapeJavaMap)), new LookupTranslator(EntityArrays.JAVA_CTRL_CHARS_ESCAPE),...
Java
= { 'enableSimplify': false, 'enableClip': false }; var Curve = function (_LineString) { _inheritsLoose(Curve, _LineString); function Curve() { return _LineString.apply(this, arguments) || this; } var _proto = Curve.prototype; _proto._arc = function _arc(ctx, points, lineOpaci...
JavaScript
"""); } [Fact] public void fails_with_neither() { ShouldFailRule(_ => { _.Query = """ { argValidation } """; _.Error(err => { err.Message = "Must provide str1 or...
C#
move d3,d6 muls d1,d5 * xsin@ muls d0,d6 * zcos@ add.l d5,d5 add.l d6,d6 swap d5 swap d6 add d6,d5 * Z'=xsin@+zcos@ move d4,(a2)+ addq #2,a2 move d5,(a2)+ dbra d7,bucle_y end_y * Rotation autour de l'axe des Z: * X'=xcos@+ysin@ * Y'=-xsin@+ycos@ move (a1)+,d0 tst d0 * Y-a-t-il rotation? beq e...
Assembly
t/uploads/2016/11/20161124200956.png" alt="20161124200956" width="784" height="521" data-srcset="http://www.mottoin.com/wp-content/uploads/2016/11/20161124200956.png 784w, http://www.mottoin.com/wp-content/uploads/2016/11/20161124200956-300x199.png 300w, http://www.mottoin.com/wp-content/uploads/2016/11/20161124200956-...
HTML
serif !default; $h1-size: 40px; $h2-size: 28px; $h3-size: 22px; $h4-size: 19px; $h5-size: 16px; $h6-size: 14px; // Grays // ------------------------- $black: #000 !default; $grayDarker: #222 !default; $grayDark: #333 !default; $gr...
CSS
let s = Math.sin(angle); let c = Math.cos(angle); let t = 1 - c; let a00 = mat[0]; let a01 = mat[1]; let a02 = mat[2]; let a03 = mat[3]; let a10 = mat[4]; let a11 = mat[5]; let a12 = mat[6]; let a13 = mat[7]; let a20 = mat[8]; ...
Typescript
// - one conditional branch, // - one conditional branch followed by one unconditional branch. // Otherwise, assume not-taken. assert(MI.isConditionalBranch()); const MachineBasicBlock &B = *MI.getParent(); bool SawCond = false, Bad = false; for (const MachineInstr &I : B) { if (!I.isBra...
C++
from services.vulnerability_intelligence.handlers.base_handler import BaseHandler from models.vulnerability_intelligence import VulnerabilityIntelligence from dateutil import parser as dateutil_parser class CisaKevHandler(BaseHandler): def apply(self, vuln_intelligence: VulnerabilityIntelligence): try: ...
Python
] | 0;\n var bl9 = b9 & 0x1fff;\n var bh9 = b9 >>> 13;\n\n out.negative = self.negative ^ num.negative;\n out.length = 19;\n /* k = 0 */\n lo = Math.imul(al0, bl0);\n mid = Math.imul(al0, bh0);\n mid = (mid + Math.imul(ah0, bl0)) | 0;\n hi = Math.imul(ah0, bh0);\n var w0 = (((c + lo) | 0) ...
JavaScript
ally { // Close the spanner client when finished. // The databaseAdminClient does not require explicit closure. The closure of the Spanner client will automatically close the databaseAdminClient. spanner.close(); } // [END spanner_create_storing_index] } async function queryDataWithIndex( instanceId,...
JavaScript
underline("__this is an__ underlined string"), Some((Underline(vec![Text("this is an".to_owned())]), 14)) ); assert_eq!( parse_underline("__testing__ underlined__ strings"), Some((Underline(vec![Text("testing".to_owned())]), 11)) ); } #[test] fn ...
Rust
parentNetworkingNode.OCPP.CustomCustomDataSerializer ); #region Send OnRequestStartTransactionRequestFiltered event await LogEvent( OnRequestStartTransactionRequestFiltered, ...
C#
cadastrante, lotaCadastrante, mob, movNaoAss.getIdMov()); } } } public void incluirCosignatario(final DpPessoa cadastrante, final DpLotacao lotaCadastrante, final ExDocumento doc, final Date dtMov, final DpPessoa subscritor, final String funcaoCosignatario) throws AplicacaoException { incluirCosignatario...
Java
�吗?' title='给猫打疫苗需要找血管吗?可以自己打吗?'>给猫打疫苗需要找血管吗?可以自己打吗?</a> </li> </ul><h2 id='猫舍可以自己打疫苗吗'>猫舍可以自己打疫苗吗</h2> <p>是可以的。<a href="http://www.to3158.cn/tags-m-m.html" target="_blank" class="relatedlink">猫咪</a>的疫苗是打在他的<a href="http://www.to3158.cn/tags-p-x65db601e8a22b.html" target="_blank" class="relatedlink">皮下</a><a href="http...
HTML
到 CIA 的利益。他说,「我和 CIA 的信息总管,首席技术官,其它技术部门的首席主管坐在一起,他们会告诉我最困难的技术问题,我的工作即找出修补问题的方法。」</p> <p>但是在2012年3月,斯诺登又一次为戴尔公司工作,这一次是到夏威夷的一个巨大掩体中,他在那里成为了信息共享办公室的领头技术专家,专注于技术问题。「通道」内——湿冷的、冷飕飕的、有25万平方英尺的凹坑,曾是一个存储鱼雷的设施,斯诺登对于 NSA 的能力和缺乏监管的担心与日俱增。在这些已发现的秘密中,最令他震惊的是,NSA 经常传输未经处理的私人通信给以色列的情报部门,通信内容和元数据一样。通常类似这样的信息都会被「最小化」处理,姓名和个人可识别的数据会被移除。但...
HTML
td><div class="topbar"><a href="AArch32-regindex.html">AArch32 Registers</a></div></td><td><div class="topbar"><a href="AArch64-regindex.html">AArch64 Registers</a></div></td><td><div class="topbar"><a href="AArch32-sysindex.html">AArch32 Instructions</a></div></td><td><div class="topbar"><a href="AArch64-sysindex.html...
HTML
!= 302) { throw Exception("got code ${it.code()} instead of 302") } it.headers().forEach { if (it.first == "location") { return@map "&state=([^&]*)&".toRegex().find(it.second)!!.groupValues[1] } } throw Exception("Cannot log in (can't follow red...
Kotlin
在要传的数据后加0。 2. 模2除法。 3. 最终发送的数据:要发送的数据+FCS。 ![CRC](imgs-CN\2CRC.jpg) - 如果余数为0,判定这个帧没有差错。(接受) - 如果余数不为0,判定这个帧有差错。(丢弃) FCS的生成以及接收端CRC检验都是由**硬件实现**的,处理很迅速,不会产生延迟数据。 **只使用CRC**:凡是接收端数据链路层接受的帧均无差错。能够实现无比特差错的传输,但不是可靠传输(因为错误的帧丢弃了,接收端并没有收到)。 **可靠传输**:数据链路层发什么,接收端就接收什么。 #### 2.5.3海明码 可以发现**双**比特错,但是只能纠正**单**比特错。 工...
Markdown
seedError: '', seeds: removeById(action.id)(state.seeds) }; }; const addThumbnailToSeed = (state: any, action: any) => { const index: number = findIndexById(action.id, state.seeds); if (index >= 0) { return R.assocPath(['seeds', index, 'imageUrl'], action.imageUrl)(state); } return state; }; const se...
Typescript
.matrix.createMatrix(HEIGHT, WIDTH, draw.LedColor.RED)); }, DEFAULT_DURATION / 3); setTimeout(() => { draw.drawStill(BRIGHTNESS, draw.matrix.createMatrix(HEIGHT, WIDTH, draw.LedColor.GREEN)); }, (DEFAULT_DURATION * 2) / 3); }, label: 'Should draw multi...
Typescript
r"""可访问资源数量 :rtype: int """ return self._AssetCount @AssetCount.setter def AssetCount(self, AssetCount): self._AssetCount = AssetCount @property def LogCount(self): r"""访问/行为日志数量 :rtype: int """ return self._LogCount @LogCount.set...
Python
difficulty: block.difficulty ? BigInt(block.difficulty) : undefined,\n gasLimit: block.gasLimit ? BigInt(block.gasLimit) : undefined,\n gasUsed: block.gasUsed ? BigInt(block.gasUsed) : undefined,\n hash: block.hash ? block.hash : null,\n logsBloom: block.logsBloom ? block.logsBloom : n...
JavaScript
만 선택 가능하며, 한 번 선택하면 바꿀 수 없습니다!", DIFFICULTY_DESCRIPTION_LEGACYOFBHAAL_BG2EE = "적에게 매우 어려움 난이도의 모든 이점에 더해 상당한 추가 생명점, THAC0, 내성 굴림, 라운드 당 공격 횟수 보정이 붙습니다. 주의: 바알의 유산 난이도는 게임을 시작할 때만 선택 가능하며, 한 번 선택하면 바꿀 수 없습니다!", DIFFICULTY_DESCRIPTION_LEGACYOFBHAAL_BGEE = "적에게 매우 어려움 난이도의 모든 이점에 더해 상당한 추가 생명점, THAC0, 내성 굴림, 라운드 당 공격 횟...
Lua
## Example Generation after pretraining ############################################################ ######################################################################################################################## print("Generating") prompt = "Hello W" generate_after_training(model, prompt, tokenizer, temp=0.0...
Python
9wxACFvX+BreDMCARDRqBICJ+nBv5E8DwCL5kcpuAzB9agDAcRMb8f1pAIgnqA1NTf8AlALoDwIA/JHJ2wDgLgDzNNI+EgCITzcAcNP/4QAkg2+u5H4ZAM3T65HHTS0Az6qYCLPycPyjL122DsXPKXE1cVCzw0vkbM7kqvSNYDq+lB+y8vCZ86Q3OWQ6LoyDJhNULkoAoFFDC7CKc2ViezmYIr9Y+HScKUtggxgwahYDJhd+1kEE1N6HPoqYCvvyziouMgMxAAdA5nUxQDNJBTMQ+B4LQOiOhp9vWoIHa78Hm8cW9yxjgwv2bEpW+H73...
HTML
R",S_data_mode_snapshot_letter:"S",R_data_mode_replay_letter:"R","Quotes are delayed by {0} min and updated every 30 seconds":"報價延遲 {0} 分鐘,每30秒更新一次","Quotes are delayed by {0} min":"報價延遲 {0} 分鐘","Hide Favorite Drawings Toolbar":"隱藏最愛繪圖工具列","Save Drawing Template As...":"儲存繪圖範本為...","Apply Default Drawing Template":"套用預...
HTML
> HasSeek for Cursor<T> { } impl<'a> HasSeek for PeekCursor<'a> { } impl<T: Seek + Read> HasSeek for SeekPeekReader<T> { } impl<T> AsSeek for BufPeekReader<T> { } make_as_trait!(BufRead); impl<T: AsRef<[u8]>> HasBufRead for Cursor<T> { } impl<'a> HasBufRead for PeekCursor<'a> { } impl<T: Read> HasBufRead for BufPeekRe...
Rust
1 # PREAGG: B #main# #foo_secondary# 1 1 ## main calls foo at valid instruction offset past nops that are to be stripped. .globl main main: .cfi_startproc call foo_secondary ret .cfi_endproc .size main,.-main ## Placeholder cold fragment to force main to be ignored in non-relocation mode. .globl main.col...
Assembly
IVs; minimum values are based on a hindering nature, 0 EVs, 0 IVs. --- ## Forms & Evolutions !!! warning "WARNING" Information on evolutions may not be 100% accurate; differences between evolution methods across generations are not accounted for. ### Forms Magmortar has no alternate forms. ### Evolution Line...
Markdown
0.29863 0.37262,-0.4909 -0.27411,-0.29826 0.30382,-0.43586 0.50279,-0.17665 0.58535,-0.56193 -0.30203,-8.13832 5.94587,-0.314"},"55053":{"name":"Jackson, WI","path":"m 602.4228,157.66314 3.9758,-0.193 0.0963,1.994 1.93189,-0.11105 0.15942,2.00605 5.99401,-0.337 1.97542,-0.169 0.21468,4.20784 0.16989,2.07735 -2.58632,0....
JavaScript
#ifndef _VSP_GRAPHIC_PICKABLE_H #define _VSP_GRAPHIC_PICKABLE_H #include "SceneObject.h" #include <string> namespace VSPGraphic { class ColorBuffer; class Renderable; /*! * Base class for all Pickable objects. */ class Pickable : public SceneObject { public: /*! * Constructor. * source - The source prov...
C
们十分恶毒地咒骂站在以毛主席为代表的无产阶级革命路线上的人是“冒失的‘左’派应受到鄙视”。反革命修正主义集团的黑干将李琪放肆地攻击说:“这几年的问题就出在反右倾上”,“再一反右,错误就更严重了,因此成为全国性的问题,这就是路线问题。”在“中央文件摘抄”的按语中,他们胡说,庐山会议以后,“要求过了头”,“农村人民公社,工业生产计划,技术革命等方面的问题都比较多”,极力攻击庐山会议。他们别有用心的叫嚷,“路线性问题纠正起来是很困难的,党的历史上凡属路线错误,都不是能靠自己纠正的。”这一语道破了彭、刘反革命修正主义集团篡党、篡国的野心。言下之意,就是要推翻毛主席的正确领导,让他们的“英明宰相”和反革命的“杂家”、“智囊团”上台。请看,这一...
HTML
reflectiveQuadTo(80f, 480f) quadToRelative(0f, -83f, 31.5f, -156f) reflectiveQuadTo(197f, 197f) quadToRelative(54f, -54f, 127f, -85.5f) reflectiveQuadTo(480f, 80f) quadToRelative(83f, 0f, 156f, 31.5f) reflect...
Kotlin
hr abliefert."}}, [12667] = {"Sucht die Windschlangengöttin auf", nil, {"Geht zum Altar von Quetz'lun und sucht Quetz'luns Geist auf."}}, [12668] = {"Den Weg zur Rache ebnen", nil, {"Quetz'luns Geist am Altar von Quetz'lun hat Euch damit beauftragt, in der Nähe ihrer Seelenbrunnen 12 Trolle zu töten. Diese können entwe...
Lua
nge nodes { if redis.IsPrimaryWithSlot(node) { primaries = append(primaries, node) } else if redis.IsReplica(node) { replicas = append(replicas, node) } else if redis.IsPrimaryWithNoSlot(node) { primariesWithNoSlots = append(primariesWithNoSlots, node) } } return primaries, replicas, primariesWithNoS...
Go
mage %} {% capture overlay_img_path %}{{ page.header.overlay_image | absolute_url }}{% endcapture %} {% endif %} {% if page.header.overlay_filter contains "rgba" %} {% capture overlay_filter %}{{ page.header.overlay_filter }}{% endcapture %} {% elsif page.header.overlay_filter %} {% capture overlay_filter %}rgba...
HTML
EncodingSimulcastAv1PacketGenerator(3) runInOrderTest(generator, getIndex(eid = 0, dt = 0)) { it.spatialId == 0 && it.temporalId == 0 } } private class ProjectedPacket constructor( val packet: Av1DDPacket, val origSeq: Int, val extOrigSeq: Long, val e...
Kotlin
-1 1.2 2 ''' for device in self.devices: fsa0 = k2.Fsa.from_str(s0).to(device).requires_grad_(True) fsa1 = k2.Fsa.from_str(s1).to(device).requires_grad_(True) fsa2 = k2.Fsa.from_str(s2).to(device).requires_grad_(True) fsa_vec = k2.create_fsa_v...
Python
ice context (DC) to which send data (pixels/RGB(A) colors) let screen = GetDC(None); let pixels_upperleftcorner_x = 0; let pixels_upperleftcorner_y = 0; // https://docs.microsoft.com/en-us/windows/win32/api/wingdi/nf-wingdi-transparentblt TransparentBlt( screen.to_...
Rust
#!/usr/bin/env python # -*- coding: utf-8 -*- # Created by TaoYuan on 2017/12/17. # @Link : http://blog.csdn.net/lftaoyuan # Github : https://github.com/seeways # @Remark : Python学习群:315857408 # Python提供了HTMLParser来非常方便地解析HTML from html.parser import HTMLParser # 查找标记和其他标记和调用处理程序函数 from html.entities import name...
Python
4, 16)}; auto Trunc = B.buildTrunc(S33, {Copies[0]}); auto Trunc1 = B.buildTrunc(S48, {Copies[0]}); auto Vector = B.buildBitcast(V3S16, Trunc1); auto FreezeScalar = B.buildInstr(TargetOpcode::G_FREEZE, {S64}, {Copies[0]}); auto FreezeOdd = B.buildInstr(TargetOpcode::G_FREEZE, {S33}, {Trunc}); auto FreezeV...
C++
utputs) merged.append(m) return merged if __name__ == "__main__": # Testing code below. It creates a simple model to train on MNIST and # tries to run it on 2 GPUs. It saves the graph so it can be viewed # in TensorBoard. Run it as: # # python3 parallel_model.py import...
Python
感。**Pantera**与**Sepultura**代表这一风格,用简练有力的riff推动金属乐进入新的表演方式。 ## 时代冲击:Groove Metal的诞生与蜕变 20世纪80年代末到90年代初,西方音乐世界充满变革。彼时,主流金属乐逐渐走向饱和,而地下音乐圈则酝酿着前所未有的新能量。**Groove Metal**正是在这样的历史节点脱颖而出。它起源于美国南部,尤其以德克萨斯州为中心。此时,乐迷对于以速度和技巧为核心的**Thrash Metal**逐渐感到疲劳,寻求更具新意的表达方式。音乐人和制作人不断尝试,将金属的侵略性与更具律动的结构融合,逐步孕育出*Groove*的核心:简洁、厚重、有力的节奏。 发生在198...
Markdown
.setPlayerIndex(primary->getControllingPlayer()->getPlayerIndex()); sound.setPosition(primary->getPosition()); } TheAudio->addAudioEvent(&sound); } static void parse(INI *ini, void *instance, void* /*store*/, const void* /*userData*/) { static const FieldParse myFieldParse[] = { { "Name", I...
C++
// Copyright (c) Microsoft Corporation. // Licensed under the MIT License. using UnityEngine.Events; using UnityEngine.EventSystems; namespace Microsoft.MixedReality.Toolkit.Experimental.InteractiveElement.Examples { /// <summary> /// Example receiver class for the Keyboard state /// </summary> publi...
C#
</td> <td> <em></em> </td> </tr> <tr class="cg-1"> <td></td> <td> &#160;&#160;&#160; <a href="index.html#module-storycraftr.utils.core" ><code class="xref...
HTML
; //Base value is ballsize*ballQ*cumefficiency by a factor of 2. //Other things that affect it: //lust - 50% = normal output. 0 = half output. 100 = +50% output. //trace("CUM ESTIMATE: " + int(1.25*2*cumMultiplier*2*(lust + 50)/10 * (hoursSinceCum+10)/24)/10 + "(no balls), " + int(ballSize*balls*cumMultip...
Typescript
--fa: "\f632"; --fa--fa: "\f632\f632"; } .fa-tire-pressure-warning { --fa: "\f633"; --fa--fa: "\f633\f633"; } .fa-tire-rugged { --fa: "\f634"; --fa--fa: "\f634\f634"; } .fa-tired { --fa: "\f5c8"; --fa--fa: "\f5c8\f5c8"; } .fa-toggle-large-off { --fa: "\e5b0"; --fa--fa: "\e5b0\e5b0"; } .fa-toggle-large-on { --fa: "\e5b1...
CSS
// speedup in some scenarios. program += &format!(r#" unsafe {{ let old_size = self.buf.len(); let new_size = old_size + {}; if new_size > self.buf.capacity() {{ self.buf.reserve(new_size - old_size); ...
Rust
ALBOAT -> R.drawable.ic_boat_rental_pedalboat SUP -> R.drawable.ic_boat_rental_standup_paddleboard ROWBOAT -> R.drawable.ic_boat_rental_rowboat SAILBOAT -> R.drawable.ic_boat_rental_sailboat RAFT -> R.drawable.ic_boat_rental_raft SURFBOARD -> R.drawable.ic_boat_rental_surfboard SAI...
Kotlin
>? after null shorting completes.) var iterableDouble = <double>[] as Iterable<double>; contextIterableQuestion( (test?.pIterableIntQuestion ??= iterableDouble) ..expectStaticType<Exactly<Iterable<num>?>>(), ); // This example has: // - K = Function? // - T1 = Function? // - T...
Dart
mWriter<BinaryGeometry> WRITER$ = (org.apache.avro.io.DatumWriter<BinaryGeometry>)MODEL$.createDatumWriter(SCHEMA$); @Override public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException { WRITER$.write(this, SpecificData.getEncoder(out)); } @SuppressWarnings("unchecked") privat...
Java
.85442 6.25 8.25 6.85442 8.25 7.6V12V16.9C8.25 17.6456 8.85442 18.25 9.6 18.25H12V17.5C12 18.25 12.0003 18.25 12.0007 18.25L12.0015 18.25L12.0033 18.25L12.0076 18.25L12.0197 18.2498C12.0292 18.2497 12.0415 18.2494 12.0566 18.249C12.0867 18.2481 12.1276 18.2463 12.1779 18.243C12.2782 18.2365 12.4171 18.2236 12.582 18.19...
CSS
contiguous in memory. ''' if self._spatial_radius is None: raise ValueError("Spatial radius has not been set") if self._range_radius is None: raise ValueError("Range radius has not been set") if self._min_density is None: raise...
Python
ion.length == 40){ var version = 'Development'; } exec(untarcmd, function (err, stdout) { fs.unlinkSync(remote_folder + 'menus.tar.gz'); fs.writeFileSync('/config/menuversion.txt', version); layermenu(function(response){ disablesigs(); callback(null, 'done'); }); }); } // Grab rem...
JavaScript
de acechavermis", [78662] = "Vestimentas del interior de la tierra", [78663] = "Coselete de placas óseas necróticas", [78664] = "Guerrera de malla de batalla de Colmillo Negro", [78665] = "Vestimenta del interior de la tierra", [78666] = "Guantes del caminaespíritus", [78667] = "Mandiletes del caminaespíritus", [78668...
Lua
LiYuc9kEtDqzPO6rYcZMRlLtFTNLEXTznzqPAoDQ3DcNjzKDdSrES0shhia4YlykelYx/fLcZNRihzQyEMgxju88eWepjoEtHqpLGeZxiosW+amN+YsyeYEIJoEOw6o5F9ZEuzK5/Ty0Orw+zB9cyyLJg541SDq2ONECK8MAwNxyGuE11bW2lJcnlokGWWbMPiYOk655lHv0JQW1DsuoKJ0HEc12V2JFMMS255aHXGOTGN9ThG45qW5zFTUE6JgKeZcIEmzHVgsQFSrEz0RpaAC3d5PKYW9QQ8jRQLJZqEduSExH7uWFN1dFloZTGeoY...
CSS
{ position: 'top', height: 57, body: 'top'}, { position: 'left', width: 200, resize: true, body: 'left', gutter: '5px', collapse: true, collapseSize: 25, header: 'Modules', scroll: true, animate: true }, { position: 'center', body: 'center', gutter: '5px' }, { position: 'right', width: 32...
JavaScript
b.com/d2-projects/d2-admin/commit/3bc9ccc03d2a75eeec9f9fb0e3623a7a4000025a])\n * 增加动态添加表单字段示例 (d931710 [https://github.com/d2-projects/d2-admin/commit/d9317107e916f1014b8e0f21ad7648786d7f782f])\n\n# 1.11.0 [https://github.com/d2-projects/d2-admin/compare/@d2-plus/d2-crud-plus-example@1.10.2...@d2-plus/d2-crud-plus-exam...
JavaScript
function to call when the shortcut matches */ export function useShortcut( shortcut: string | null, onPress: (e: KeyboardEvent) => void, { rootElement }: ShortcutOptions = {}, ) { useEffect(() => { if (!shortcut) { return undefined; } return installShortcut(shortcut, onPress, { rootElement }...
Typescript
Did you get any writing done today?", "When will you stop wasting time plotting fractals?" ], body ); } #[test] /// You can turn almost any iterator into a peekable iterator by calling the Iterator /// trait's peekable method. /// Calling peek tries t...
Rust
if (column.dontShowReply) { add("mention") add("reply") } if (column.dontShowReaction) { add("reaction") } if (column.dontShowVote) { add("poll_vote") ...
Kotlin
w = sampleRate, h = signal, }:setStroke(false) :setFill(true) :setFillColor(signalColor) :orderAbove(drawings[#drawings]) :setBehaviorByLabels{"canJoinAllSpaces"} :show() ) table.insert(drawings, #drawings, drawing.rectangle{ x = base...
Lua
translateY(-3px); box-shadow: 0 10px 25px rgba(255, 167, 38, 0.4); } .btn.secondary { background: linear-gradient(45deg, #95a5a6, #7f8c8d); } .btn.secondary:hover { box-shadow: 0 10px 25px rgba(149, 165, 166, 0.4); } .footer-info { ...
HTML
Self::Output { unsafe{ let ptr = self.get_unchecked((MIN as usize)..=(MAX as usize)).as_ptr().cast(); &*ptr } } } #[allow(clippy::cast_sign_loss)] impl<T, const N: usize, const MIN: irang, const MAX: irang> core::ops::IndexMut<iter::ConstRange<MIN, MAX>> for [T; N] where ...
Rust
/*Heat method field value computing*/ /*Written by Guoxin Fang 08-15-2020 (last updated)*/ #ifndef HEATMETHOD_H #define HEATMETHOD_H #include "PolygenMesh.h" #include "../GLKLib/GLKObList.h" class heatMethod { public: heatMethod(QMeshPatch* inputMesh); ~heatMethod(); void compBoundaryHeatKernel(); ...
C
��시지를 TLS 핸드쉐이크의 암호화 단계 이후로 옮긴 것입니다(1.3 이전에는 평문으로 전송되었습니다). 이런 프로토콜의 근본적인 변경 없이는 공격자가 네트워크를 통해서 전송되는 평문 인증서를 보는 것 만으로 서버의 정체를 알아낼 수 있을 것입니다.</p> <p>기반이 되는 암호화 기술은 클라이언트와 서버가 신뢰할 수 없는 통신에서 공유하는 암호화 키를 만들어낼 수 있다는 <a href="https://ko.wikipedia.org/wiki/%EB%94%94%ED%94%BC-%ED%97%AC%EB%A8%BC_%ED%82%A4_%EA%B5%90%ED%99%98">디...
HTML
# cook your dish here n = int(input()) if(n%2==0): print(1) else: print(2)
Python
telegramdesktop/tdesktop/blob/master/LEGAL */ #include "window/themes/window_themes_generate_name.h" #include "base/random.h" namespace Window { namespace Theme { namespace { const auto kColors = base::flat_map<uint32, const char*>{ { 0x8e0000U, "Berry" }, { 0xdec196U, "Brandy" }, { 0x800b47U, "Cherry" }, { 0xff...
C++
f extAxis2 = worldObb.Extent[ 2 ] * worldObb.Axis[ 2 ]; Vector3f vertex[ 8 ]; vertex[ 0 ] = worldObb.Center - extAxis0 - extAxis1 - extAxis2; vertex[ 1 ] = worldObb.Center + extAxis0 - extAxis1 - extAxis2; vertex[ 2 ] = worldObb.Center + extAxis0 + extAxis1 - extAxis2; vertex[ 3 ] = worldObb.Center - ex...
C++
p *)abuf; /* We really want libpcap to give us aligned packets */ if (!didwarn) { warning("compensating for unaligned libpcap packets"); ++didwarn; } } #endif if ((u_char *)(ip + 1) > snapend) { printf("[|ip]"); return; } if (length < sizeof (struct ip)) { (void)printf("truncated-ip %d", length); ...
C
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; using IO.Eventuate.Tram.Events.Common; using IO.Eventuate.Tram.Events.Publisher; using IO.Eventuate.Tram.Events.Subscriber; using IO.Eventuate.Tram.Messaging.Common; using IO.Eventu...
C#
// <auto-generated> // automatically generated by the FlatBuffers compiler, do not modify // </auto-generated> namespace SCHALE.Common.FlatData { public enum ParcelChangeReason : int { None = 0, Acquire_NewAccount = 1, Acquire_PlayReward = 2, Acquire_ChapterReward = 3, Acquire_LoginReward = 4, Acquire_Ev...
C#
( {2}, TensorType_STRING, {0x00, 0x00, 0x00, 0x20, 16, 0, 0, 0, 17, 0, 0, 0, 18, 0, 0, 0, 'A', 'B'}, "input"); builder.FinishModel({}, {}); ASSERT_FALSE(builder.Verify()); ASSERT_FALSE(builder.VerifyWithOpResolver()); EXPECT_THAT( builder.GetErrorString(), ::testing::ContainsRegex(...
C++
Output: "2.71", expectedRuntimeCost: 11, expectedEstimatedCost: checker.CostEstimate{Min: 11, Max: 11}, locale: "en_US", }, { name: "default list precision for string", format: "%s", formatArgs: "[2.71]", expectedOutput: ...
Go
Jd0pQ== sig=uKSSajmX0e2eL9HGUjtr1yqlzT23xAEEhZxLJlezcFwm3XLrNa9TIzssdhqByD3Y7GKwez41uWmAq3MN4OCq7Hadp3vmO24T8bIe62sbk+jPrnl4Qel58Rscdz6ER1Shh9Fy5WQRpzWNfPPi+o5DVz4A e=found last=14 s=5 in addShifted_NP", "pub=MEMwBQYDK2VxAzoA0H/4fiqDsOmzDikk9W8UyLONX8b0afWXZ7WutuQb+tMj2lC41D9m7Nm00ej/TCKf4A+/2EcwCJSA pr...
C#
nls.builtins.formatting.black, nls.builtins.formatting.gofumpt, nls.builtins.formatting.dart_format.with({ cmd = "/opt/flutter/bin/cache/dart-sdk/bin/dart" }), nls.builtins.formatting.csharpier } -- followed...
Lua
documentation isIconified - https://developer.android.com/reference/android/widget/SearchView#setIconified(boolean) maxWidth - https://developer.android.com/reference/android/widget/SearchView#setMaxWidth(int) setOnSearchClickListener - https://developer.android.com/reference/android/widget/Sea...
Kotlin
'8', '9', 'A', 'B', 'C', 'D', 'E', 'F'}; //Send the chip ID as a standard USB string on EP0IN. //The ID is 10 hexadecimal digit*2 (UTF-16)+lenght+type=22Bytes void usbSendIdString(void) { int i=0; IN0BUF[0] = 22; IN0BUF[1] = STRING_DESCRIPTOR; for (i=0; i<5; i++) { IN0BUF[2+(i*4)] = bin2he...
C
program and the accompanying materials * are made available under the terms of the Eclipse Public License v2.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v20.html * * Contributors: * IBM Corporation - initial API and implementation *************************...
JavaScript
><a href="class/src/low_level/geometries/Geometry.js~Geometry.html#instance-method-_setVertexNtoSingleMaterial">_setVertexNtoSingleMaterial</a></span></span><span class="code" data-ice="signature">(material: <span>*</span>, index: <span>*</span>)</span> </p> </div> <div> ...
HTML
, 182, 191, 234, 290, 330, 310], itemStyle: { normal: { color: colors[1] } }, }, { z: 2, name: '底部', type: 'pictorialBar', data: [1, 1, 1, 1, 1, 1, ...
HTML
{ avg_angle = 0; } if (Math.abs(avg_angle) > Math.PI / 2 - SLANT_TOLERANCE) { avg_angle = Math.PI / 2; } for (i = 0; i < nsides; ++i) { r1 = recos[recognizer_queue_length - nsides + i]; r1.angle = avg_angle + i * Math.PI / 2; } double[] pt = new double[2]; double[] points = new double[10]; ...
Java
31-.35.4a.75.75 0 0 1-.5.07l-.11-.03h-.01a.75.75 0 0 1-.47-.85v-.01l.04-.11 3.5-9.01Zm-.75 5.5h2.9L6 4 4.55 7.73Z\" fill=\"url(#paint0_linear_378174_9679)\"/><path d=\"m10.3 16.94 5.58-5.61-3.2-3.21-5.6 5.61.53 2.69 2.69.52Z\" fill=\"url(#paint1_linear_378174_9679)\"/><path d=\"M9.87 17.17c.2-.08.4-.2.55-.35 0 0-.97.1-...
C#
ublic void UserCommentDescription_ZeroLengthAscii2() { // fill the 10-byte encoding region var commentBytes = "ASCII\x0\x0\x0\x0\x0"u8.ToArray(); var directory = new ExifSubIfdDirectory(); directory.Set(ExifDirectoryBase.TagUserComment, commentBytes); ...
C#
return OS; } raw_ostream &VersionInfoBlock::log(raw_ostream &OS) const { OS << " Start of block (name: " << Name << ")\n"; for (auto &Stmt : Stmts) Stmt->log(OS); return OS << " End of block\n"; } raw_ostream &VersionInfoValue::log(raw_ostream &OS) const { OS << " " << Key << " =>"; size_t NumValues ...
C++
H8GBgYGJgYkAABURgPz6Ks7wQAAAABJRU5ErkJggg==);background-position:bottom left;background-repeat:repeat-x}.CodeMirror-merge-r-chunk{background:#ffffe0}.CodeMirror-merge-r-chunk-start{border-top:1px solid #ee8}.CodeMirror-merge-r-chunk-end{border-bottom:1px solid #ee8}.CodeMirror-merge-r-connect{fill:#ffffe0;stroke:#ee8;s...
HTML
r)); grid-auto-rows: 1fr; gap: 16px; border-top: 1px solid rgba(55, 53, 47, 0.16); padding-top: 16px; padding-bottom: 4px; } .notion-gallery-card { display: block; color: inherit; text-decoration: none; box-shadow: rgba(15, 15, 15, 0.1) 0px 0px 0px 1px, rgba(15, 15, 15, 0.1) 0px 2px 4px; border-...
CSS
cted = to_vec(Struct { tag: "Struct", content: value }); assert_eq!(to_vec(s), expected); } /// Тестирует запись перечислений со значениями разных видов при из записи без тега #[test] fn test_enum_untagged() { #[derive(Serialize)] #[serde(untagged)] enum E { ...
Rust
equal(crc32.hash(raw), -(parseInt("EC4AC3D0", 16) + 1) ^ -1, 'crc32'); }; /* http://pajhome.org.uk/crypt/md5/ */ /* Original text Hello, World! Original bytes 48:65:6c:6c:6f:2c:20:57:6f:72:6c:64:21 (length=13) Adler32 1f9e046a CRC32 ec4ac3d0 Haval 69329e93ccfd832bb1a4ee00d01344cf M...
JavaScript
f): """ステップインジケーターの更新とクリーンアップ""" from src.facilities.ui.wizard_service_panel import WizardServicePanel panel = Mock() mock_indicator_panel = Mock() panel.indicator_panel = mock_indicator_panel with patch.object(panel, '_create_step_indicator') as mock_cr...
Python
/* * memset - fill memory with a constant byte * * Copyright (c) 2012-2024, Arm Limited. * SPDX-License-Identifier: MIT OR Apache-2.0 WITH LLVM-exception */ /* Assumptions: * * ARMv8-a, AArch64, Advanced SIMD, unaligned accesses. * */ #include "asmdefs.h" #define dstin x0 #define val x1 #define valw w1 #def...
Assembly
/**************************************************************************** **************************************************************************** *** *** This header was automatically generated from a Linux kernel header *** of the same name, to make information necessary for userspace to *** call i...
C
>v_oversample, // 0, 0, // glyph) // // if (spc->h_oversample > 1) // stbtt__h_prefilter(spc->pixels+r->x+r->y*spc->stride_in_bytes, // r->w, r->h, spc->stride_in_bytes, // spc->h_oversample) // // ...
Kotlin
I_CALL_UNEXPECTED_ERROR, {{ Type::String.borrow()|lower_fn }}(e.toString()), ) ) } } val handle = uniffiForeignFutureHandleMap.insert(job) uniffiOutDroppedCallback.uniffiSetValue(UniffiForeignFutureDroppedCallbackStruct(handle, uniffiForeignFutureDropp...
Kotlin
k 的地址 address owner = 0x0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045; // 从已知私钥创建一个地址; address owner = vm.addr(privateKey); // 创建一个攻击者 address hacker = 0x00baddad; ``` ## msg.sender 和 tx.origin 的恶作剧 在上述示例中,`msg.sender` 被更改。如果你想同时控制 `tx.origin` 和 `msg.sender`,`vm.prank` 和 `vm.startPrank` 都可以选择性地接受两个参数,其中第二个参数是 `tx.orig...
Markdown
onStateChange[GLOBAL_KEY] = function(sc) if sc ~= SC_MAP_LOADED or df.global.gamemode ~= df.game_mode.DWARF then return end local persisted_data = dfhack.persistent.getSiteData(GLOBAL_KEY, {}) -- convert the string keys back into enum values g_watched_job_matchers = {} for k,v in pairs(p...
Lua
rranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, ...
Kotlin