What do you want to save?
Add Code snippet
New code examples
-
C++ 2022-03-13 06:15:02
static inside local scope in c++
#include<iostream> //Singleton class is a class having only one instance class SingleTon { public: static SingleTon& Get() { static SingleTon s_Instance; return s_Instance; }//there is only one instance of static functions and variables a... Add solution -
Javascript 2022-01-28 22:12:40
generics with function expressions
Generic functions // Something like the following works fine: function foo<T>(x: T): T { return x; } // However using an arrow generic function will not: const foo = <T>(x: T) => x; // ERROR : unclosed `T` tag // Workaround: Use extend... Add solution -
Other 2021-10-27 03:50:15
windows.h
windows.h is a Windows-specific header file for the C and C++ programming languages which contains declarations for all of the functions in the Windows API, all the common macros used by Windows programmers, and all the data types used by the various f... Add solution -
C++ 2021-10-23 02:18:07
how to calculate trigonometric values in c++
* * C++ Program to Illustrate Trigonometric functions */ #include <iostream> #include <iomanip> #include <cmath> const double PI = 3.14159265; int main() { double degrees, radians; std::cout << "Enter angle in de... Add solution -
VBA 2021-10-02 07:07:04
excel vba difference between DateValue and CDate
'Difference between CDate() and DateValue(). 'In VBA, these two intrinsic functions seem to do the same 'thing... convert values from different data types into the 'corresponding value of the Date data type. 'But CDate() is more capable; it can retain t... Add solution -
Javascript 2021-09-22 06:51:01
Web3 Example
// Here's how we would access our contract: var abi = /* abi generated by the compiler */ var ZombieFactoryContract = web3.eth.contract(abi) var contractAddress = /* our contract address on Ethereum after deploying */ var ZombieFactory = ZombieFactoryCont... Add solution -
C# 2021-09-22 06:42:02
unity object pooling
using System.Collections; using System.Collections.Generic; using UnityEngine; [System.Serializable] public class ObjectPoolItem { public GameObject objectToPool; public int amountToPool; public bool shouldExpand = true; public ObjectPoolItem(Game... Add solution -
Javascript 2021-09-18 07:21:02
combination with repetition algorithm js
(() => { 'use strict'; // COMBINATIONS WITH REPETITIONS ------------------------------------------- // combsWithRep :: Int -> [a] -> [[a]] const combsWithRep = (k, xs) => { const comb = (n, ys) => { ... Add solution
Best helpers
Colocvial
+5
Tjd
+5
Zagi
+5
Tobiak777
+5
Leosar
+5
Sarah witte
+5
Gouri
+5
Gabi Purcaru
+5
Pooria Han
+5
Skry
+5
Mladenka
+5
Yoyo
+5
Thorba
+5
L. Samson
+5