This file contains hidden or 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
| /*************************************************************************** | |
| * _ _ ____ _ | |
| * Project ___| | | | _ \| | | |
| * / __| | | | |_) | | | |
| * | (__| |_| | _ <| |___ | |
| * \___|\___/|_| \_\_____| | |
| * | |
| * Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al. | |
| * | |
| * This software is licensed as described in the file COPYING, which |
This file contains hidden or 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 <stdio.h> | |
| #include <stdlib.h> | |
| #include <poll.h> | |
| #include <uv.h> | |
| static void on_close(uv_handle_t* handle); | |
| static void on_connect(uv_connect_t* req, int status); | |
| static void on_write(uv_write_t* req, int status); | |
| static void on_alloc(uv_handle_t* handle, size_t suggested_size, uv_buf_t* buf) |
This file contains hidden or 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 <windows.h> | |
| #include <wininet.h> | |
| #include <stdio.h> | |
| #pragma comment (lib, "Wininet.lib") | |
| int main(int argc, char *argv[]) { | |
| HINTERNET hSession = InternetOpen( | |
| L"Mozilla/5.0", // User-Agent |
This file contains hidden or 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 <memory> | |
| #include <cassert> | |
| #include <Windows.h> | |
| struct FileHandle | |
| { | |
| ::HANDLE fileHandle; | |
| //implicit | |
| FileHandle(::HANDLE h) noexcept |
This file contains hidden or 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
| if (BUILD_APPLE_BUNDLE) | |
| set(EXEC_NAME "MyUI") | |
| else () | |
| get_filename_component(EXEC_NAME "${CMAKE_CURRENT_SOURCE_DIR}" NAME) | |
| string(APPEND EXEC_NAME "-${PROJECT_VERSION}") | |
| endif () | |
| set(Source_Files "main.c") | |
| source_group("Source Files" FILES "${Source_Files}") |
This file contains hidden or 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
| #region license | |
| /* | |
| This file is public domain. | |
| You may freely do anything with it. | |
| Copyright (c) VPKSoft 2019 | |
| */ | |
| #endregion | |
| using System; |
This file contains hidden or 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
| /** \file WinMain.cpp | |
| * \author rhoot <https://github.com/rhoot> | |
| * | |
| * \brief Redirects calls from the windows specific WinMain() entry point to a more | |
| * standard main() entry point defined someplace else. In debug builds, also | |
| * allocates a console and redirects stdin, stderr, stdout to that console. | |
| * | |
| * \remark The std* stream redirection is based on RedirectIOToConsole(), as can be found | |
| * at http://dslweb.nwnexus.com/~ast/dload/guicon.htm. | |
| */ |
This file contains hidden or 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
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Runtime.InteropServices; | |
| namespace MyCSharpApp | |
| { |
This file contains hidden or 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
| Rem run as administrator | |
| @echo on & @setlocal enableextensions | |
| @echo ========================= | |
| @echo Turn off the time service | |
| net stop w32time | |
| @echo ====================================================================== | |
| @echo Set the SNTP (Simple Network Time Protocol) source for the time server | |
| w32tm /config /syncfromflags:manual /manualpeerlist:"0.it.pool.ntp.org 1.it.pool.ntp.org 2.it.pool.ntp.org 3.it.pool.ntp.org" | |
| @echo ============================================= | |
| @echo ... and then turn on the time service back on |
This file contains hidden or 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
| """ | |
| A demo comparison of three different implementations for estimating Lempel-Ziv complexity (1976) | |
| Implementations compared: | |
| - Pure Python version, by Naereen | |
| - Numba (str), as implemented in EntroPy by Raphael Vallat | |
| - Numba, updated for speed, based on numpy integer arrays | |
| Simple comparisons for equality of estimates and performance to address issue: | |
| https://github.com/raphaelvallat/entropy/issues/14 |
NewerOlder