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
#!/bin/bash | |
# | |
# This script is for Ubuntu 20.04 Focal Fossa to download and install XRDP+XORGXRDP via | |
# source. | |
# | |
# Major thanks to: http://c-nergy.be/blog/?p=11336 for the tips. | |
# | |
############################################################################### |
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
Console.WriteLine("Hi") |
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
UPDATE | |
sales.commissions | |
SET | |
sales.commissions.commission = | |
c.base_amount * t.percentage | |
FROM | |
sales.commissions c | |
INNER JOIN sales.targets t | |
ON c.target_id = t.target_id; |
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
$ServerName = '192.168.1.188' | |
$DatabaseName = 'Dbname' | |
$UserName = 'username' | |
$password = 'password' | |
$connectionString = 'Data Source={0};database={1};User ID={2};Password={3}' -f $ServerName,$DatabaseName,$userName,$password | |
$sqlConnection = New-Object System.Data.SqlClient.SqlConnection $connectionString | |
$sqlConnection.Open() |
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
#Size of RAM disk desired(MB) * 2048 = amount to specify | |
#Using the above example, that would be: | |
#eg 2GB 2048 * 2048 = 4194304 | |
diskutil erasevolume HFS+ 'RAMDisk' `hdiutil attach -nomount ram://524288` # 0.5GB | |
diskutil erasevolume HFS+ 'RAMDisk' `hdiutil attach -nomount ram://4194304` # 2GB | |
diskutil erasevolume HFS+ 'RAMDisk' `hdiutil attach -nomount ram://8388608` # 4GB | |
diskutil erasevolume HFS+ 'RAMDisk' `hdiutil attach -nomount ram://12582912` # 6GB |
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
{"lastUpload":"2017-10-22T16:07:49.429Z","extensionVersion":"v2.8.3"} |
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
public class PhraseOMatic3 { | |
public static void main(String[] args) { | |
String[] girls = {"Amanda", "Jessica", "Chrissie"}; | |
String[] verbs = {"loves", "hates"}; | |
String[] boys = {"Andy", "Aaron", "Eason", "Jacky"}; | |
for (String girl : girls) { // for each string in girls[] | |
int j = (int) (Math.random() * verbs.length); | |
int k = (int) (Math.random() * boys.length); | |
System.out.println(girl + " " + verbs[j] + " " + boys[k]); | |
} |