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 boto3 | |
import csv | |
def check_ec2_without_tag(tags_key_to_search, session): | |
# Initialize the EC2 client using the provided session | |
ec2_client = session.client('ec2') | |
# Define a dictionary to store instances without the given tag | |
instances_without_tag = [] |
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 boto3 | |
import csv | |
def list_accounts_in_organization(): | |
# Initialize the Organizations client | |
org_client = boto3.client('organizations') | |
accounts = [] | |
# Pagination loop |
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 boto3 | |
import csv | |
def list_unencrypted_volumes(session): | |
# Initialize the EC2 client using the provided session | |
ec2_client = session.client('ec2') | |
unencrypted_volumes = [] | |
next_token = None |
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
#const max_singer = 5. | |
#const max_baudi = 100. | |
singer(marco_mengoni,35,1,2,0,1,26). | |
singer(giorgia,40,0,0,0,2,25). | |
singer(ultimo,40,2,0,0,0,27). | |
singer(lazza,110,1,0,0,1,22). | |
singer(elodie,90,0,0,0,2,24). | |
singer(madame,110,0,1,0,1,22). | |
singer(colapesce_dimartino,150,1,0,0,1,20). |
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
/* appearance */ | |
static const char font[] = "-*-terminus-medium-r-*-*-16-*-*-*-*-*-*-*"; | |
static const char normbordercolor[] = "#444444"; | |
static const char normbgcolor[] = "#151515"; | |
static const char normfgcolor[] = "#aaaaaa"; | |
static const char selbordercolor[] = "#151515"; | |
static const char selbgcolor[] = "#151515"; | |
static const char selfgcolor[] = "#ff8c00"; | |
static const unsigned int gappx = 2; | |
static const unsigned int borderpx = 1; /* border pixel of windows */ |
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 boto3 | |
import json | |
import re | |
import requests | |
from bs4 import BeautifulSoup | |
from pathlib import Path | |
BASE_URL = "YOUR_BASE_URL" | |
CONTENT_BUCKET = "YOUR_BUCKET_NAME" |
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
include "qelib1.inc"; | |
// ALICE CODE | |
// create a 3 qubit register | |
qreg q[3]; | |
// create a 3 single qubit register | |
creg c0[1]; | |
creg c1[1]; | |
creg c2[1]; |
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
... | |
x := 0 | |
res := pipeline(unit(x), f1, f2, f3) | |
fmt.Printf("%s\n", res.ToString()) | |
... |
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
... | |
func pipeline(x *Log, fs ...Increment) *Log { | |
for _, f := range fs { | |
x = bind(x, f) | |
} | |
return x | |
} |
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
... | |
func (l *Log) ToString() string { | |
return fmt.Sprintf("Res: %d, Ops: %s", l.Val, l.Op) | |
} | |
... |
NewerOlder