I hereby claim:
- I am jonasraoni on github.
- I am jonasraoni (https://keybase.io/jonasraoni) on keybase.
- I have a public key whose fingerprint is C6B8 2A63 2F58 4784 159E 802F 5ECC 07E6 0269 4752
To claim this, I am signing this object:
| function GetBit(const Value: DWord; const Bit: Byte): Boolean; | |
| begin | |
| Result := (Value and (1 shl Bit)) <> 0; | |
| end; | |
| function EnableBit(const Value: DWord; const Bit: Byte; const TurnOn: Boolean): DWord; | |
| begin | |
| Result := (Value or (1 shl Bit)) xor (Integer(not TurnOn) shl Bit); | |
| end; |
| #include <stdio.h> | |
| #define ALIGN_OF(t) ((int)(sizeof(struct{char c; t x;}) - sizeof(t))) | |
| int main() | |
| { | |
| printf("char: %d\n", ALIGN_OF(char)); | |
| printf("short: %d\n", ALIGN_OF(short)); | |
| printf("int: %d\n", ALIGN_OF(int)); | |
| printf("long: %d\n", ALIGN_OF(long)); |
| var _, D; | |
| (_ = function(){return this["trela".match(/\w/g)["reverse"]().join("")];})[false] = "jonas"; | |
| _()(_[ (_(_)===D )]); |
| using System; | |
| using System.Text.RegularExpressions; | |
| namespace Raoni { | |
| public static class Utils { | |
| private string queryLimit(string query, uint limit, uint? offset) { | |
| if(limit > 0) { | |
| offset = offset == null ? 0 : offset; | |
| if(offset < 0) | |
| throw new Exception("LIMIT argument offset=" + offset + " is not valid"); |
| SELECT | |
| C.Table_Name, | |
| C.Constraint_Name, | |
| C.Constraint_Columns | |
| FROM | |
| ( | |
| SELECT | |
| object_name(i.object_id) table_name, i.name index_name, | |
| MAX(CASE index_column_id when 1 THEN col_name(ic.object_id,ic.column_id) ELSE '' END) + | |
| MAX(CASE index_column_id when 2 THEN col_name(ic.object_id,ic.column_id) ELSE '' END) + |
| using System; | |
| using System.IO; | |
| using System.Web; | |
| using System.Text; | |
| using System.Collections.Generic; | |
| using System.Collections; | |
| namespace Raoni { | |
| public delegate bool Generator<T>(out T value); | |
| public delegate bool Enumerator<T>(T value); |
| class Increment{ | |
| constructor(value) { | |
| this.current = +value || 0; | |
| }; | |
| [Symbol.toPrimitive]() { | |
| return ++this.current; | |
| } | |
| } | |
| var increment = new Increment(); |
I hereby claim:
To claim this, I am signing this object:
| EXEC sp_addlinkedserver @server='SERVER_ADDRESS'; | |
| EXEC sp_addlinkedsrvlogin @rmtsrvname='SERVER_ADDRESS',@useself=false, @rmtuser='USER', @rmtpassword='PASSWORD'; | |
| -------------- | |
| INSERT INTO LOCAL_TABLE | |
| SELECT * | |
| FROM | |
| [SERVER_ADDRESS].DATABASE.dbo.REMOTE_TABLE |
| /* | |
| There is a table in database. This table contains unduplicated natural numbers. There may be gaps in the sequence of natural numbers in the table. You need to output missing numbers. | |
| Table of natural numbers: declare @values as table ([number] int not null). | |
| Test data: insert into @values([number]) values (1), (2), (3), (5), (9). | |
| Result: declare @missing as table ([left] int not null, [right] int not null). | |
| */ | |
| DECLARE @values AS TABLE ([number] INT NOT NULL); | |
| INSERT INTO @values([number]) VALUES (1), (2), (3), (5), (9); | |
| DECLARE @missing AS TABLE ([left] INT NOT NULL, [right] INT NOT NULL) |