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 threading | |
from collections import deque | |
from typing import List, Optional | |
class _LightSwitch: | |
"""An auxiliary "light switch"-like object. The first thread turns on the | |
"switch", the last one turns it off (see [1, sec. 4.2.2] for details).""" | |
def __init__(self): |
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
#!/bin/bash | |
### ATLAS Ubuntu install | |
# Assign user name | |
if [[ -v SUDO_USER ]]; then | |
UserName=$SUDO_USER | |
echo sudo user name found: $SUDO_USER | |
else | |
read -p "Enter your user name: " UserName | |
fi |