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 javax.swing.*; | |
public class HelloWorldSwing { | |
/** | |
* Create the GUI and show it. For thread safety, | |
* this method should be invoked from the | |
* event-dispatching thread. | |
*/ | |
private static void createAndShowGUI() { | |
//Create and set up the window. |
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 javax.swing.*; | |
public class HelloWorldSwing { | |
/** | |
* Create the GUI and show it. For thread safety, | |
* this method should be invoked from the | |
* event-dispatching thread. | |
*/ | |
private static void createAndShowGUI() { | |
//Create and set up the window. |
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
from tkinter import * | |
window = Tk() | |
window.title("Welcome to LikeGeeks app") | |
lbl = Label(window, text="Hello") | |
lbl.grid(column=0, row=0) |
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
type VectorAng2 = { | |
mag: number, | |
dir: number, | |
dim: 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
function addSimultaneousEventListeners(eventNames, callback, options) { | |
const defaultOptions = { | |
inOrder: true, // the events should be fired in the order specified in eventNames array or not | |
tolerance: 500, // the tolerance time between the first and the last event in milliseconds, | |
// you can rarely fire two events at the exact moment | |
} | |
// merge default options with user options | |
const mergedOptions = { | |
...defaultOptions, | |
...options |
NewerOlder