What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-10-21 10:32:10
how many threads does node js use
Node.js runs JavaScript code in the Event Loop (initialization and callbacks), and offers a Worker Pool to handle expensive tasks like file I/O. Node.js scales well, sometimes better than more heavyweight approaches like Apache. The secret to the scalabil... Add solution -
Javascript 2021-10-20 20:42:11
how to automatically create hyperlink in readme
/* Here is javascript code for automatically getting link attached to content of readme.md file. Full Code - https://gist.github.com/SBZed/490f5d9eac525de02f610a28f0c9453c */ LinkHeadingToContent(headingText) { headingList = headingText.split('\n'); ... Add solution -
SQL 2021-10-19 23:25:08
could not execute statement; sql [n/a]; constraint [null]; nested exception is org.hibernate.exception.constraintviolationexception: could not execute statement
@Entity @Table(name = "bankuser") public class User implements java.io.Serializable { /** * */ private static final long serialVersionUID = 6447416794596398975L; @Id @GeneratedValue(strategy = GenerationType.IDENTITY... Add solution -
Java 2021-10-16 20:37:05
addition of two binary numbers in java
import java.util.Scanner; public class JavaExample { public static void main(String[] args) { long b1, b2; int i = 0, carry = 0; int[] sum = new int[10]; Scanner scanner = new Scanner(System.in); System.out.print("Enter first binary numb... Add solution -
Java 2021-10-15 18:48:20
static data and static methods in java
class JavaExample{ private static String str = "BeginnersBook"; //Static class static class MyNestedClass{ //non-static method public void disp() { /* If you make the str variable of outer class * non-static then you will g... Add solution -
Java 2021-10-12 10:28:05
how to compare two characters in java
public class JavaCharacterCompareExample1 { public static void main(String[] args) { char firstValue = 'A'; char secondValue = 'B'; // compare the first char to the second int compareOneTwo = Character.compare(firstValue, secondValue); ... Add solution -
Javascript 2021-10-10 08:55:12
what is eval in js
The eval() function evaluates JavaScript code represented as a string. console.log(eval('2 + 2')); // expected output: 4 console.log(eval(new String('2 + 2'))); // expected output: 2 + 2 console.log(eval('2 + 2') === eval('4')); // expected output: tru... Add solution