This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package = ktor.cinterop.winhttp | |
headers = wtypes.h winhttp.h | |
headerFilter = winhttp.h | |
compilerOpts = -DUNICODE | |
linkerOpts = -lwinhttp | |
--- | |
// These WebSocket declarations are not present in our sysroots, | |
// so we add them here. | |
#define WINHTTP_OPTION_UPGRADE_TO_WEB_SOCKET 114 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import kotlin.system.measureNanoTime | |
enum class MyEnum { | |
ITEM1, ITEM2, ITEM3, ITEM4, ITEM5, ITEM6, ITEM7, ITEM8, ITEM9, ITEM10, ITEM11, ITEM12, ITEM13, ITEM14, ITEM15, ITEM16, ITEM17, ITEM18, ITEM19, ITEM20, ITEM21, ITEM22, ITEM23, ITEM24, ITEM25, ITEM26, ITEM27, ITEM28, ITEM29, ITEM30, ITEM31, ITEM32, ITEM33, ITEM34, ITEM35, ITEM36, ITEM37, ITEM38, ITEM39, ITEM40, ITEM41, ITEM42, ITEM43, ITEM44, ITEM45, ITEM46, ITEM47, ITEM48, ITEM49, ITEM50, ITEM51, ITEM52, ITEM53, ITEM54, ITEM55, ITEM56, ITEM57, ITEM58, ITEM59, ITEM60, ITEM61, ITEM62, ITEM63, ITEM64, ITEM65, ITEM66, ITEM67, ITEM68, ITEM69, ITEM70, ITEM71, ITEM72, ITEM73, ITEM74, ITEM75, ITEM76, ITEM77, ITEM78, ITEM79, ITEM80, ITEM81, ITEM82, ITEM83, ITEM84, ITEM85, ITEM86, ITEM87, ITEM88, ITEM89, ITEM90, ITEM91, ITEM92, ITEM93, ITEM94, ITEM95, ITEM96, ITEM97, ITEM98, ITEM99, ITEM100 | |
} | |
private fun enumSwitch(x: MyEnum) : Int { | |
when (x) { | |
MyEnum.ITEM5 -> return 1 | |
MyEnum.ITEM10 -> return 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <type_traits> | |
#include <variant> | |
#include <vector> | |
#include <typeinfo> | |
int main() { | |
std::variant<std::string, int, bool> mySetting = "Hello!"; | |
if (std::holds_alternative<bool>(mySetting)) { | |
std::cout << "WAT" << std::endl; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.github.aceisnotmycard.contollers; | |
import com.github.aceisnotmycard.repositories.entities.BaseEntity; | |
import org.springframework.data.jpa.repository.JpaRepository; | |
import org.springframework.web.bind.annotation.*; | |
import java.util.List; | |
class BaseController<Entity extends BaseEntity> { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Created by Sergey Bogolepov on 24/12/15. | |
// | |
#ifndef SMART_PTR_SMART_PTR_H | |
#define SMART_PTR_SMART_PTR_H | |
#include <iostream> | |
template<typename T> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.aceisnotmycard.redtooth.communication; | |
import android.bluetooth.BluetoothAdapter; | |
import android.bluetooth.BluetoothDevice; | |
import android.bluetooth.BluetoothServerSocket; | |
import android.bluetooth.BluetoothSocket; | |
import android.content.BroadcastReceiver; | |
import android.content.Context; | |
import android.content.Intent; | |
import android.content.IntentFilter; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT emp.employee_id, | |
emp.last_name, | |
emp.salary, | |
emp.department_id | |
FROM hr.employees emp | |
WHERE emp.salary = | |
(SELECT min(salary) | |
FROM hr.employees b | |
WHERE emp.department_id = b.department_id) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT loc.country_id, sum(emp.salary) sum_salary | |
FROM hr.employees emp | |
JOIN hr.departments dep ON emp.department_id = dep.department_id | |
JOIN hr.locations loc ON dep.location_id = loc.location_id | |
GROUP BY loc.country_id | |
ORDER BY loc.country_id DESC, sum_salary DESC |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT a.employee_id, COUNT(*) | |
FROM hr.employees a | |
JOIN hr.employees b ON a.employee_id = b.manager_id | |
JOIN hr.departments dep ON a.department_id = dep.department_id | |
JOIN hr.locations loc ON dep.location_id = loc.location_id | |
WHERE loc.country_id = | |
(SELECT country_id | |
FROM hr.locations loc | |
JOIN hr.departments dep ON dep.location_id = loc.location_id | |
GROUP BY country_id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// factory.h | |
// Prisoners Dilemma II | |
// | |
// Created by Sergey Bogolepov on 11/24/14. | |
// Copyright (c) 2014 Sergey Bogolepov. All rights reserved. | |
// | |
#ifndef Prisoners_Dilemma_II_factory_h | |
#define Prisoners_Dilemma_II_factory_h |
NewerOlder