Skip to content

Instantly share code, notes, and snippets.

View janouwehand's full-sized avatar

Jan Ouwehand janouwehand

View GitHub Profile
"Create a resource group and storage account (V2, Standard_LRS, with identity)"
""
$AppName = Read-Host 'What is the storage accounts name?'
$Location = "West Europe"
$ResourceGroupName = "${AppName}-group"
""
$confirmation = Read-Host "Are you Sure You Want To Proceed (typ y)"
"Create a resource group, app service plan and web app (West Europe, Linux on F1)"
""
$AppName = Read-Host 'What is the app name?'
$Location = "West Europe"
$ResourceGroupName = "${AppName}-group"
$AppServicePlanName = "${AppName}-plan"
""
@janouwehand
janouwehand / gist:ad0e132ed857b0cbbbaeaaf0ce6c0b85
Last active May 18, 2023 15:47
Prime number generation of given bitsize using Miller-Rabin primality test
public static class PrimeNumbers
{
private static BigInteger GeneratePrime(int bitsize)
{
var i = 0;
BigInteger p;
using (var rng = RandomNumberGenerator.Create())
{
var bytes = new byte[bitsize / 8];
do