text stringlengths 1 1.05M |
|---|
gdt_start: ; don't remove the labels, they're needed to compute sizes and jumps
; the GDT starts with a null 8-byte
dd 0x0 ; 4 byte
dd 0x0 ; 4 byte
; GDT for code segment. base = 0x00000000, length = 0xfffff
; for flags, refer to os-dev.pdf document, page 36
gdt_code:
dw 0xffff ; segment length, bi... |
;/*!
; @file
;
; @brief BvsGetPhysBuf DOS wrapper
;
; (c) osFree Project 2021, <http://www.osFree.org>
; for licence see licence.txt in root directory, or project website
;
; This is Family API implementation for DOS, used with BIND tools
; to link required API
;
; @author Yuri Prokushev (yuri.prokushev@g... |
////////////////////////////////////////////////////////////////////////////////
// Author: Andy Rushton
// Copyright: (c) Southampton University 1999-2004
// (c) Andy Rushton 2004 onwards
// License: BSD License, see ../docs/license.html
// Contains all the platform-specific socket handling... |
;
; Sharp OZ family functions
;
; ported from the OZ-7xx SDK by by Alexander R. Pruss
; by Stefano Bodrato - Oct. 2003
;
;
; gfx functions
;
; int ozputs(int x, int y, char *string);
;
; ------
; $Id: ozputs.asm,v 1.4 2016-06-28 14:48:17 dom Exp $
;
SECTION smc_clib
PUBLIC ozputs
PUBLIC _ozputs
PUBLIC ozput... |
lev80
; PF0
byte %00000000
byte %00000000
byte %00000000
byte %11111111
byte %11111111
byte %11111111
byte %11111111
byte %11111111
byte %11111111
byte %11111111
byte %00000000
byte %00000000
; PF1
byte %00000000
byte %00000000
byte %00111111
byte %11111111
byte %11111111
byt... |
SECTION code_fp_math32
PUBLIC l_f32_invf
EXTERN m32_fsinv_fastcall
defc l_f32_invf = m32_fsinv_fastcall
|
extern m7_ippsECCPSetStdSM2:function
extern n8_ippsECCPSetStdSM2:function
extern y8_ippsECCPSetStdSM2:function
extern e9_ippsECCPSetStdSM2:function
extern l9_ippsECCPSetStdSM2:function
extern n0_ippsECCPSetStdSM2:function
extern k0_ippsECCPSetStdSM2:function
extern ippcpJumpIndexForMergedLibs
extern ippcpSafeInit:funct... |
; A093149: a(1) = 4; a(n) = (n^(n+1)+2*n-3)/(n-1) for n > 1.
; 4,9,42,343,3908,55989,960802,19173963,435848052,11111111113,313842837674,9726655034463,328114698808276,11966776581370173,469172025408063618,19676527011956855059,878942778254232811940,41660902667961039785745,2088331858752553232964202
add $0,1
mov $2,$0
lpb ... |
; Low level interrupt/thread handling code for GeekOS.
; Copyright (c) 2001,2003,2004 David H. Hovemeyer <daveho@cs.umd.edu>
; Copyright (c) 2003,2014 Jeffrey K. Hollingsworth <hollings@cs.umd.edu>
; $Revision: 1.18 $
; All rights reserved.
; This code may not be resdistributed without the permission of the copyright ... |
frame 1, 05
frame 2, 10
frame 3, 10
endanim
|
; A026915: a(n) = T(n,0) + T(n,1) + ... + T(n,n), T given by A026907.
; 1,26,100,272,640,1400,2944,6056,12304,24824,49888,100040,200368,401048,802432,1605224,3210832,6422072,12844576,25689608,51379696,102759896,205520320,411041192,822082960,1644166520,3288333664,6576667976,13153336624,26306673944,52613348608,1052266979... |
#include <CGAL/Polygon_mesh_processing/measure.h>
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Polyhedron_3.h>
#include <CGAL/Surface_mesh.h>
#include <CGAL/Polygon_mesh_processing/bbox.h>
#include <CGAL/Bbox_3.h>
#inclu... |
.global s_prepare_buffers
s_prepare_buffers:
ret
.global s_faulty_load
s_faulty_load:
push %r10
push %r11
push %r14
push %r8
push %r9
push %rdx
push %rsi
// Store
mov $0xa80, %rdx
xor $65173, %r10
movw $0x5152, (%rdx)
nop
nop
nop
nop
nop
sub %r14, %r14
// Store
lea addresses_US+0xdbe2, %r8
nop
nop
cmp $40505, %r... |
//===--- SemaCast.cpp - Semantic Analysis for Casts -----------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
// ===== push Argument 1 =====
@1
D=A
@ARG
A=M+D
D=M
@SP
A=M
M=D
// SP++
@SP
M=M+1
// ===== pop Pointer 1 ======
@THAT
D=A
@R13
M=D
// SP--
@SP
M=M-1
A=M
D=M
@R13
A=M
M=D
// ===== push Constant 0 =====
@0
D=A
@SP
A=M
M=D
// SP++
@SP
M=M+1
// ===== pop That 0 ======
@0
D=A
@THAT
D=M+D
@R13
M=D
// SP--
@SP
M=M-1
A... |
//
// Copyright 2019 Autodesk
//
// 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 applicable law or agreed to in ... |
; A086801: a(n) = prime(n) - 3.
; -1,0,2,4,8,10,14,16,20,26,28,34,38,40,44,50,56,58,64,68,70,76,80,86,94,98,100,104,106,110,124,128,134,136,146,148,154,160,164,170,176,178,188,190,194,196,208,220,224,226,230,236,238,248,254,260,266,268,274,278
cal $0,40 ; The prime numbers.
sub $0,3
mov $1,$0
|
global long_mode_start
section .text
bits 64
long_mode_start:
mov ax, 0
mov ss, ax
mov ds, ax
mov es, ax
mov fs, ax
mov gs, ax
extern rust_main
call rust_main
; print `OKAY` to screen
mov rax, 0x2f592f412f4b2f4f
mov qword [0xb8000], rax
hlt
|
;-------------------------------------------------------------------------
; Read/write driver for serial eeprom memory for micro8085_cilb
; Functions below assumes support for INTEL 8085 "undocumented" opcodes
SECTION code_clib
EXTERN eepgsz
EXTERN sprxbf
EXTERN spirx
EXTER... |
.section __DATA,__data
# __DATA er segment, __data er seksjon (ref Mach-O format)
.section __TEXT,__text
# __TEXT er segment, __text er seksjon (fef Mach-0 format)
# din kode
|
; void SMS_VRAMmemcpy_brief(unsigned int dst,void *src,unsigned char size)
SECTION code_clib
SECTION code_SMSlib
PUBLIC SMS_VRAMmemcpy_brief
EXTERN asm_SMSlib_VRAMmemcpy_brief
SMS_VRAMmemcpy_brief:
pop af
pop bc
pop de
pop hl
push hl
push de
push bc
push af
ld b,c
jp asm_SMSlib_V... |
JMP END
LABEL START
LD R0, 1
LD R1, 2
ADD R0, R1
LD R2, 5
LD R3, 3
SUB R2, R3
LD R0, 3
LD R1, 5
MUL R0, R1
LD R2, 10
LD R3, 2
DIV R2, R3
LABEL END
JMP START
|
// Copyright 2016 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "src/compiler/redundancy-elimination.h"
#include "src/compiler/node-properties.h"
#include "src/compiler/simplified-operator.h"
namespace v8 ... |
.data
zero: .float 0.0
.text
main:
la $t0, zero
l.s $f0, 0($t0)
div.s $f0, $f0, $f0
mov.s $f1, $f0
c.le.s 5, $f0, $f1
bc1t 5, branch
li $a0, 0
li $v0, 1
syscall
branch:
li $a0, 1
li $v0, 1
syscall |
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Copyright (c) GeoWorks 1992 -- All Rights Reserved
PROJECT: PC GEOS
MODULE:
FILE: spreadsheetColumn.asm
AUTHOR: Gene Anderson, Aug 27, 1992
ROUTINES:
Name Description
---- -----------
MSG_SPREADSHEET_SET_ROW_HEIGH... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "ui/events/keycodes/keyboard_code_conversion_x.h"
#define XK_3270 // for XK_3270_BackTab
#include <X11/keysym.h>
#include <X11/Xlib.h>
#inc... |
//------------------------------------------------------------------------------
//
// Copyright (c) 2016, Linaro Limited. All rights reserved.
//
// This program and the accompanying materials
// are licensed and made available under the terms and conditions of the BSD License
// which accompanies this distribution. ... |
#include "TrackInfoG4.hpp"
#include "G4VProcess.hh"
using namespace allpix;
TrackInfoG4::TrackInfoG4(int custom_track_id, int parent_track_id, const G4Track* const aTrack)
: custom_track_id_(custom_track_id), parent_track_id_(parent_track_id) {
auto G4Process = aTrack->GetCreatorProcess();
origin_g4_proce... |
; A131912: Row sums of triangle A131911.
; 1,7,12,18,23,29,34,40,45,51,56,62,67,73,78,84,89,95,100,106,111,117,122,128,133,139,144,150,155,161,166,172,177,183,188,194,199,205,210,216,221,227,232,238,243,249,254,260,265,271,276,282,287,293,298
mul $0,11
add $0,3
div $0,2
mov $1,$0
|
/*
* Copyright 2010-2016 Amazon.com, Inc. or its affiliates. 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.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file... |
at (32)
:index pad (2)
:extra_length_bits pad (2)
:length_value pad (2)
:extra_distance_bits pad (2)
:distance_value pad (2)
at (42)
set (requested_feedback_location, 0)
at (64)
:byte_copy_left pad (2)
:byte_copy_rig... |
// This file is part of www.nand2tetris.org
// and the book "The Elements of Computing Systems"
// by Nisan and Schocken, MIT Press.
// File name: projects/04/Mult.asm
// Multiplies R0 and R1 and stores the result in R2.
// (R0, R1, R2 refer to RAM[0], RAM[1], and RAM[2], respectively.)
// Put your code here.
@R2
M=... |
include mathhost.i
CGROUP group code
code segment dword 'CODE'
assume cs:CGROUP,ds:CGROUP
MATHLIB_2JUMP sinh _r_ml_sinh math_sinh
code ends
end
|
; Reverses the bits within a byte.
;
; Uses: a,b,c
;
; Entry: a a byte
; Exit: a a with its bits reversed.
reverse_bits: ld c,8
ld b,a ; b is now the input value.
xor a ; clear for output.
__reverse_bits_loop: sla a
srl b ; c >>> 1
jp nc,__reverse_bits_cont
or a,1
__reverse_bits_cont: dec c
ret z
... |
\ LCD CONFIG -- cfg_2x16_lcd.asm -----------------------------------------------
\
\ Port B of the VIA is used for the Data pins on the LCD display.
\ Three pins on Port A are used for signal pins on the LCD:
\ - PA5 RS Register select
\ - PA6 RW Read/Write
\ - PA7 E Execute
\ The other 5 pins - PA0-PA4 - a... |
_zombie: file format elf32-i386
Disassembly of section .text:
00000000 <main>:
#include "stat.h"
#include "user.h"
int
main(void)
{
0: 8d 4c 24 04 lea 0x4(%esp),%ecx
4: 83 e4 f0 and $0xfffffff0,%esp
7: ff 71 fc push -0x4(%ecx)
a: 55 pus... |
%define sys_write 0x04
%define sys_rt_sigaction 0x43
%define sys_pause 0x1d
%define sys_exit 0x01
%define sys_rt_sigreturn 0xad
%define SIGTERM 0x0f
%define SIGINT 0x02
%define SIGSEGV 0xb
%define STDOUT 0x01
%define SA_RESTORER 0x04000000
; Definition of sigaction struct for sys_rt_sigaction
struc sigaction
.sa_h... |
<%
from pwnlib.shellcraft.thumb.linux import syscall
%>
<%page args="which, value"/>
<%docstring>
Invokes the syscall getitimer. See 'man 2 getitimer' for more information.
Arguments:
which(itimer_which_t): which
value(itimerval): value
</%docstring>
${syscall('SYS_getitimer', which, value)}
|
#include "co/unitest.h"
#include "co/os.h"
namespace test {
DEF_test(os) {
DEF_case(env) {
EXPECT_EQ(os::env("CO_TEST"), fastring());
os::env("CO_TEST", "777");
EXPECT_EQ(os::env("CO_TEST"), "777");
os::env("CO_TEST", "");
EXPECT_EQ(os::env("CO_TEST"), fastring());
}
... |
;*****************************************************************************
;* MMX optimized DSP utils
;*****************************************************************************
;* Copyright (c) 2000, 2001 Fabrice Bellard
;* Copyright (c) 2002-2004 Michael Niedermayer <michaelni@gmx.at>
;*
;* This file is part o... |
; A017666: Denominator of sum of reciprocals of divisors of n.
; 1,2,3,4,5,1,7,8,9,5,11,3,13,7,5,16,17,6,19,10,21,11,23,2,25,13,27,1,29,5,31,32,11,17,35,36,37,19,39,4,41,7,43,11,15,23,47,12,49,50,17,26,53,9,55,7,57,29,59,5,61,31,63,64,65,11,67,34,23,35,71,24,73,37,75,19,77,13,79,40,81,41,83,3,85,43,29,22,89,5,13,23,93,... |
; A240567: a(n) = optimal number of tricks to throw in the game of One Round War (with n cards) in order to maximize the expected number of tricks won.
; 1,1,1,1,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7
mov $2,$0
mov $0,3
sub $2,2
add $0,$2
lpb $0
trn $3,$0
ad... |
// Copyright 2013 Google Inc. 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 required by applicable... |
#include <core/object.hpp>
#include "catch.hpp"
SCENARIO("We can test objects for intersection with rays", "[core][object]")
{
GIVEN("a object with the shape of a sphere")
{
core::object obj;
obj.shape = { { 0.0f, 0.0f, 0.0f }, 1.0f };
obj.material = {};
GIVEN("a ray pointing to the object")
... |
; A093178: If n is even then 1, otherwise n.
; 1,1,1,3,1,5,1,7,1,9,1,11,1,13,1,15,1,17,1,19,1,21,1,23,1,25,1,27,1,29,1,31,1,33,1,35,1,37,1,39,1,41,1,43,1,45,1,47,1,49,1,51,1,53,1,55,1,57,1,59,1,61,1,63,1,65,1,67,1,69,1,71,1,73,1,75,1,77,1,79,1,81,1,83,1,85,1,87,1,89,1,91,1,93,1,95,1,97,1,99
mov $1,$0
mod $1,2
pow $0,$... |
.global s_prepare_buffers
s_prepare_buffers:
push %r11
push %r14
push %r8
push %rax
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_A_ht+0x1a8ef, %rax
nop
cmp %r11, %r11
mov (%rax), %rcx
nop
nop
nop
mfence
lea addresses_WC_ht+0x19cef, %r14
nop
nop
nop
inc %r8
mov (%r14), %ebx
nop
nop
nop
nop
nop
add %rax, %rax
le... |
.global s_prepare_buffers
s_prepare_buffers:
push %r12
push %r14
push %r15
push %rax
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_D_ht+0x175ee, %rsi
lea addresses_A_ht+0xb166, %rdi
clflush (%rdi)
dec %r14
mov $85, %rcx
rep movsb
nop
and %rax, %rax
lea addresses_A_ht+0x12840, %rsi
lea addresses_UC_ht+0x18e, %rd... |
%INCLUDE "lib.h"
global _start
section .data
num1_msg db "First number: ", 0
num2_msg db "Second number: ", 0
num3_msg db "Third number: ", 0
min_msg db "Minimum number is ", 0
max_msg db "Maximum number is ", 0
endl db 10, 0
section .bss
inp_buffer resb 12
min_int resd 12
max_in... |
* Pointer version error message v0.00 Jun 1988 J.R.Oakley QJUMP
*
include 'dev8_mac_text'
*
section language
*
mktext pver,{Version trop ancienne de l'Interface Pointeur\}
*
end
|
;; ml64 Real_x64.asm
.code
;; public: void __cdecl Real10::FromDouble(double)
?FromDouble@Real10@@QEAAXN@Z proc
sub rsp, 8
movsd qword ptr [rsp],xmm1
fld qword ptr [rsp]
fstp tbyte ptr [ecx]
add rsp, 8
ret
?FromDouble@Real10@@QEAAXN@Z endp
;; public: void __cdecl Real1... |
;<ASCII To BCD>
LDA ASCII
SUI 030H
MOV B,A
LDA ASCII+1
SUI 030H
RLC ;Rotate A left
RLC ;Rotate A left
RLC ;Rotate A left
RLC ;Rotate A left
ADD B
STA BCD
HLT
BCD: db 000H
ASCII: db 037H,039H
|
/* Copyright (c) 2002,2003, 2004 CrystalClear Software, Inc.
* Use, modification and distribution is subject to the
* Boost Software License, Version 1.0. (See accompanying
* file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
* Author: Jeff Garland, Bart Garst
*/
#include "boost/date_time/posix... |
SPECIALCELEBIEVENT_CELEBI EQU $84
CelebiShrineEvent:
call DelayFrame
ld a, [wVramState]
push af
xor a
ld [wVramState], a
call LoadCelebiGFX
depixel 0, 10, 7, 0
ld a, SPRITE_ANIM_INDEX_CELEBI
call _InitSpriteAnimStruct
ld hl, SPRITEANIMSTRUCT_TILE_ID
add hl, bc
ld [hl], SPECIALCELEBIEVENT_CELEBI
ld hl, SPR... |
;
; $Id: 0x27.asm,v 1.1.1.1 2016/03/27 08:40:13 raptor Exp $
;
; 0x27 explanation - from xchg rax,rax by xorpd@xorpd.net
; Copyright (c) 2016 Marco Ivaldi <raptor@0xdeadbeef.info>
;
; This snippet performs the following operation:
;
; rax = rax>>((cl>>1) + ((cl + 1)>>1))
;
; It calculates the result of the Euclidean (i... |
; A107820: a(1)=3, a(2)=5; thereafter a(n) = n+5.
; 3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76
mov $1,$0
pow $1,2
min $1,3
add $0,$1
add $0,3
|
mov r0,#-1
mov r1,#1
mov r2,#-2
mov r3,#-3
mov r4,#-4
mov r5,#-5
mov r6,#-6
mov r7,#-7
mov r8,#-8
mov r9,#-9
halt |
; A275630: a(n) = product of distinct primes dividing prime(n)^2 - 1.
; Submitted by Christian Krause
; 3,2,6,6,30,42,6,30,66,210,30,114,210,462,138,78,870,930,1122,210,222,390,1722,330,42,510,1326,318,330,798,42,4290,2346,4830,1110,570,6162,246,3486,7482,2670,2730,570,582,462,330,11130,1554,12882,13110,2262,3570,330,2... |
CPU 686
BITS 32
%define DATA_REG 0x60
%define EOI 0x20
%define PIC1_CMD 0x20
%define PIC2_CMD 0xA0
global _mouse_isr
global _mouse_byte1
global _mouse_byte2
global _mouse_byte3
global _pack_completo
section .data
_mouse_byte1 dd 0
_mouse_byte2 dd 0
_mouse_byte3 dd 0
_pack_completo dd 0
next_byte dd 1
section .tex... |
/*++
Copyright (c) 1998-1999 Microsoft Corporation
Module Name:
csd.cxx
Abstract:
This is from the ATL sources. This provides a simple interface
for managing ACLs and SDs
Environment:
User mode
Revision History:
04/06/97 -srinivac-
Created it from ATL sources
... |
tilepal 0, GRAY, RED, WATER, WATER, GRAY, GRAY, WATER, WATER
tilepal 0, WATER, WATER, WATER, WATER, WATER, WATER, BROWN, BROWN
tilepal 0, WATER, RED, WATER, WATER, GRAY, GRAY, WATER, WATER
tilepal 0, WATER, WATER, WATER, WATER, WATER, WATER, BROWN, BROWN
tilepal 0, WATER, RED, RED, RED, RED, WATER, GRAY, GRAY
til... |
#include "stdafx.h"
#include "OggExtractor.h"
#include <string>
#include <sstream>
#include <iomanip>
OggDecryptor::OggDecryptor(TCHAR* lpInputPath, TCHAR* lpOutputDirectory)
{
m_source = File::CreateReader(lpInputPath);
m_lpOutputDirectory = lpOutputDirectory;
CreateDirectory(lpOutputDirectory, nullptr);
}
OggDe... |
; A219190: Numbers of the form n*(5*n+1), where n = 0,-1,1,-2,2,-3,3,...
; 0,4,6,18,22,42,48,76,84,120,130,174,186,238,252,312,328,396,414,490,510,594,616,708,732,832,858,966,994,1110,1140,1264,1296,1428,1462,1602,1638,1786,1824,1980,2020,2184,2226,2398,2442,2622,2668,2856,2904,3100,3150,3354,3406,3618,3672,3892,3948,4... |
; A157106: 5651522n^2 - 2541672n + 285769.
; 3395619,17808513,43524451,80543433,128865459,188490529,259418643,341649801,435184003,540021249,656161539,783604873,922351251,1072400673,1233753139,1406408649,1590367203,1785628801,1992193443,2210061129,2439231859,2679705633,2931482451,3194562313,3468945219,3754631169,4051620... |
#include <iostream>
using namespace std;
int main() {
int n = 3;
int mat[n][n];
for (int i=0; i<n; i++) {
for (int j=0; j<n; j++) {
cin >> mat[i][j];
}
}
int linhaMagica[n] = {0}, colunaMagica[n] = {0}, diagMagica[2] = {0};
for (int i=0; i<n; i++) {
for (int j=0; j<n; j++) {
... |
include io.h
cr equ 10
lf equ 13
.model small
.stack 200h
.data
newline db cr,lf,0
string db 40 dup(?)
str_in db ?
prompt1 db cr,lf,'enter the string : ',0
prompt2 db cr,lf,'enter the character : ',0
result db ?
.code
strsearch proc
mov cl,0
whiles:
cmp Byte ptr[bx],0
je endwhiles
... |
SSAnneB1F_Script:
jp EnableAutoTextBoxDrawing
SSAnneB1F_TextPointers:
db "@"
|
// Copyright (c) 2018, Smart Projects Holdings Ltd
// All rights reserved.
// See LICENSE file for license details.
/* Unit tests for MAVLink messages parser/serializer. */
#include <ugcs/vsm/mavlink.h>
#include <UnitTest++.h>
using namespace ugcs::vsm;
using namespace ugcs::vsm::mavlink;
/* Define plain format of ... |
/*
* IntelManager.cpp
*
* Created on: Apr 30, 2015
* Author: Rob Lyerly <rlyerly@vt.edu>
*/
#include <fstream>
#include <sstream>
#include <stdint.h>
/* Linux system information */
#include <sys/utsname.h>
#include "IntelManager.h"
#include "Intel.h"
#include "MSR.h"
/* Object type conversions */
#define... |
class Solution {
public:
vector<int> numMovesStones(int a, int b, int c) {
vector<int> v = {a, b, c};
sort(v.begin(), v.end());
vector<int> sizes = {v[2] - v[1] - 1, v[1] - v[0] - 1};
int minMoves = 2;
if(sizes[0] == 0 && sizes[1] == 0){
... |
#ifndef COMPILER_SCANNER_HPP
#define COMPILER_SCANNER_HPP
#include <compiler/token.hpp>
// Scanner
struct Scanner
{
const char *start;
const char *current;
int line;
int column;
};
extern Scanner g_scanner;
extern void scanner_init(const char *source);
extern Token scan_token();
#endif |
; A153600: a(n) = ((9 + sqrt(3))^n - (9 - sqrt(3))^n)/(2*sqrt(3)).
; Submitted by Jon Maiga
; 1,18,246,3024,35244,398520,4424328,48553344,528862608,5732366112,61931306592,667638961920,7186859400384,77287630177152,830602309958784,8922406425440256,95816335481139456,1028746337476170240,11043759907042186752,118545464003618... |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; ZX_01_OUTPUT_FZX
; romless driver for proportional fzx fonts
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; Windowed output terminal for proportional fzx fonts.
; Implements tty_z88dk terminal emulation.
;
; ;;;;;;;;;;;;;;;;;;;;
; D... |
/*!
* @brief General database interface
*
* @copyright Copyright (c) 2015-2019 Intel Corporation
*
* 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-... |
/**
* Copyright © 2013 - 2015 MNMLSTC
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may
* not use this software 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 applicable law or agreed ... |
;
; CPC Maths Routines
;
; August 2003 **_|warp6|_** <kbaccam /at/ free.fr>
;
; $Id: pow10.asm,v 1.2 2009/06/22 21:44:17 dom Exp $
;
INCLUDE "cpcfirm.def"
INCLUDE "cpcfp.def"
XLIB pow10
XDEF pow10c
LIB float
XREF fa
.pow10 ld hl,1
call float
ld hl,2
add hl,sp
ld a,(hl)
... |
; A315731: Coordination sequence Gal.5.301.5 where G.u.t.v denotes the coordination sequence for a vertex of type v in tiling number t in the Galebach list of u-uniform tilings.
; Submitted by Simon Strandgaard
; 1,6,12,18,22,28,32,38,44,50,56,62,68,72,78,82,88,94,100,106,112,118,122,128,132,138,144,150,156,162,168,172... |
;Lines beginning with a semicolon (like this one) are Comments, and not part of the game. Information in such lines represent pieces which existed in vanilla, but have been
;removed or replaced by this hack.
; See constants/pokemon_data_constants.asm
; The max number of evolutions per monster is MAX_EVOLUTIONS
EvosMo... |
; A153264: Numbers n such that 16*n+15 is not prime.
; Submitted by Christian Krause
; 0,3,5,6,8,9,10,12,15,17,18,19,20,21,24,25,27,30,31,32,33,34,35,36,38,39,40,41,42,43,45,47,48,49,50,51,52,54,55,57,58,59,60,62,63,65,66,69,70,72,73,74,75,77,78,80,81,83,84,85,86,87,90,93,94,95,96,99,100,101,102,104,105,106,107,108,110... |
; A161418: Number of triangles in the Y-toothpick structure after n rounds.
; 0,0,0,0,6,6,12,12,24,30
sub $0,1
mov $1,$0
sub $2,$0
mul $0,4
add $2,7
add $1,$2
div $0,$1
mod $2,2
trn $0,$2
mul $0,6
|
;------------------------------------------------------------------------------
;
; Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
; This program and the accompanying materials
; are licensed and made available under the terms and conditions of the BSD License
; which accompanies this distribution... |
musicChan2MainMenuTheme::
setRegisters $00, $00, $00, $00
.loop:
setVolume $A5
disableTerminals TERMINAL_TWO
wait SEMIBREVE * 8
enableTerminals TERMINAL_TWO
repeat 2
setFrequency NOTE_F * 2, $80
wait CROTCHET
setFrequency NOTE_D * 2, $80
wait CROTCHET
setFrequency NOTE_F * 2, $80
wait CROTCHET
setFrequen... |
/*=========================================================================
Program: GDCM (Grassroots DICOM). A DICOM library
Copyright (c) 2006-2011 Mathieu Malaterre
All rights reserved.
See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
This software is distributed WITHOUT A... |
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cctype>
#include <climits>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <iostream>
#include <iomanip>
#include <iterator>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#includ... |
; Include smsspec
.include "../dist/smsspec.asm"
; Include the files to test
.include "incrementer.asm"
; Define mocks
.ramsection "mock instances" slot 2
smsspec.mocks.start: db
RandomGenerator.generateByte instanceof smsspec.mock
smsspec.mocks.end: db
.ends
; Define an smsspec.suite label, which smsspe... |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%macro PRINTF32 1-*
pushf
pushad
jmp %%endstr
%%str: db %1
%%endstr:
%rep %0 - 1
%rotate -1
push dword %1
%endrep
push %%str
call printf
add esp, 4*%0
popad
popf
%endmacro
;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
.size 8000
.text@48
ei
jp lstatint
.text@100
jp lbegin
.data@143
80
.text@150
lbegin:
ld c, 44
ld b, 90
lbegin_waitvblank:
ldff a, (c)
cmp a, b
jrnz lbegin_waitvblank
xor a, a
ldff(40), a
ld hl, 9f00
ld b, 20
lbegin_clearvram:
dec l
ld(hl), a
jrnz lbegin_clearvram
dec h
dec b
jrnz lbegin_clearvra... |
/*******************************************************************************
*
* MIT License
*
* Copyright 2019-2020 Advanced Micro Devices, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
*... |
; A116701: Number of permutations of length n that avoid the patterns 132, 4321.
; 1,2,5,13,31,66,127,225,373,586,881,1277,1795,2458,3291,4321,5577,7090,8893,11021,13511,16402,19735,23553,27901,32826,38377,44605,51563,59306,67891,77377,87825,99298,111861,125581,140527,156770,174383,193441
mov $1,$0
mul $1,$0
mov $2,$0... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/ui/webui/chromeos/login/network_dropdown_handler.h"
#include "chrome/browser/ash/login/ui/login_display_host.h"
#include "ch... |
#include "QtGui/QBrush/qbrush_wrap.h"
#include "Extras/Utils/nutils.h"
#include "QtCore/QVariant/qvariant_wrap.h"
#include "QtGui/QColor/qcolor_wrap.h"
#include "QtGui/QPixmap/qpixmap_wrap.h"
Napi::FunctionReference QBrushWrap::constructor;
Napi::Object QBrushWrap::init(Napi::Env env, Napi::Object exports) {
Napi:... |
; A227071: Let s(m) = the set of k > 0 such that k^m ends with k. Then a(n) = least m such that s(m) = s(n).
; 1,2,3,2,5,6,3,2,9,2,11,2,5,2,3,6,17,2,3,2,21,2,3,2,9,26,3,2,5,2,11,2,33,2,3,6,5,2,3,2,41,2,3,2,5,6,3,2,17,2,51,2,5,2,3,6,9,2,3,2,21,2,3,2,65,6,3,2,5,2,11,2,9,2,3,26,5,2,3,2,81,2,3,2,5,6,3,2,9,2,11,2,5,2,3,6,33... |
// Copyright (c) 2017-2018 The NextON developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "privacydialog.h"
#include "ui_privacydialog.h"
#include "addressbookpage.h"
#include "addresstablemodel.h"
#include "bit... |
; A052481: a(n) = 2^n*(binomial(n,2) + 1).
; 1,2,8,32,112,352,1024,2816,7424,18944,47104,114688,274432,647168,1507328,3473408,7929856,17956864,40370176,90177536,200278016,442499072,973078528,2130706432,4647288832,10099884032,21877489664,47244640256,101737037824,218506461184,468151435264,1000727379968,2134598746112,4544... |
// Copyright (c) 2017, SUMOKOIN
//
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without modification, are
// permitted provided that the following conditions are met:
//
// 1. Redistributions of source code must retain the above copyright notice, this list of
// conditions... |
3C_Header:
sHeaderInit ; Z80 offset is $C20B
sHeaderPatch 3C_Patches
sHeaderTick $01
sHeaderCh $01
sHeaderSFX $80, $04, 3C_FM4, $0C, $05
3C_FM4:
sPatFM $00
dc.b nRst, $01
ssModZ80 $03, $01, $09, $FF
dc.b nCs6, $25
ssModZ80 $00, $01, $00, $00
3C_Loop1:
dc.b sHold
saVolFM $01
dc.b nCs6, $02
sLoop ... |
// Copyright (c) 2011-2015 The Bitcoin Core developers
// Copyright (c) 2014-2020 The SolD Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <qt/signverifymessagedialog.h>
#include <qt/forms/ui_signverifym... |
.global s_prepare_buffers
s_prepare_buffers:
push %r13
push %r8
push %r9
push %rbx
push %rcx
push %rdi
push %rsi
lea addresses_normal_ht+0x1a110, %rsi
clflush (%rsi)
nop
nop
nop
inc %rbx
movl $0x61626364, (%rsi)
add $8895, %rcx
lea addresses_D_ht+0x2130, %rsi
lea addresses_A_ht+0xab90, %rdi
nop
nop
xor $33166, %rbx
mov... |
;Author information
; Author name: shaochenren
; Author email: renleo@csu.fullerton.edu
;
;Program information
; Program name: Integer Arithmetic
; Programming languages: One modules in C and one module in X86
; Date program began: 2020-Sep-14
; Date program completed: 2020-Sep
; Files in this program: integ... |
/*
* This file belongs to the Galois project, a C++ library for exploiting parallelism.
* The code is being released under the terms of the 3-Clause BSD License (a
* copy is located in LICENSE.txt at the top-level directory).
*
* Copyright (C) 2018, The University of Texas at Austin. All rights reserved.
* UNIVER... |
//===--- Decl.cpp - Swift Language Decl ASTs ------------------------------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2014 - 2018 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/L... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.