Skip to content

Instantly share code, notes, and snippets.

@HauptJ
HauptJ / tex.yml
Created October 4, 2025 17:19
Ansible Playbook to Install Latex on Fedora
#!/usr/bin/env ansible-playbook
---
- name: Install and Configure LaTex
hosts: localhost
become: true
gather_facts: False
vars:
tex_live: texlive-scheme-full
tex_live_retries: 888
@HauptJ
HauptJ / editors.yml
Created October 4, 2025 17:18
Ansible Playbook to install Emacs and Vim
#!/usr/bin/env ansible-playbook
---
- name: Install Text Editors
hosts: localhost
become: true
gather_facts: False
tasks:
- name: Install Terminal Text Editors
dnf:
@HauptJ
HauptJ / ansible.sh
Created October 4, 2025 17:17
Bash script to install Ansible on Fedora
#!/usr/bin/env bash
# Ensure we have root permissions
if [[ $(/usr/bin/id -u) -ne 0 ]]; then
echo "Not running as root"
exit
fi
dnf update -y
dnf install ansible -y
@HauptJ
HauptJ / gcloud.yml
Created September 30, 2025 00:06
Install Google Cloud CLI Fedora
#!/usr/bin/env ansible-playbook
---
- name: Install Kubectl
hosts: localhost
become: true
gather_facts: false
tasks:
- name: Configure YUM repo
yum_repository:
@HauptJ
HauptJ / kubectl.yml
Created September 29, 2025 19:52
Install Kubectl on RHEL Based Systems
#!/usr/bin/env ansible-playbook
---
- name: Install Kubectl
hosts: localhost
become: true
gather_facts: false
tasks:
- name: Configure YUM repo
yum_repository:
@HauptJ
HauptJ / editors.yml
Created December 9, 2024 03:01
Single file Ansible Playbook to install text editors on Fedora
#!/usr/bin/env ansible-playbook
---
- name: Install Text Editors
hosts: localhost
become: true
gather_facts: False
tasks:
- name: Install Terminal Text Editors
dnf:
@HauptJ
HauptJ / ansible.sh
Last active December 9, 2024 03:07
Bash script to install Ansible on Fedora
#!/usr/bin/env bash
# Ensure we have root permissions
if [[ $(/usr/bin/id -u) -ne 0 ]]; then
echo "Not running as root"
exit
fi
dnf update -y
dnf install ansible -y
@HauptJ
HauptJ / tex.yml
Created December 9, 2024 02:17
Single file Ansible Playbook to install Latex Scheme Full and Latex editors on Fedora
#!/usr/bin/env ansible-playbook
---
- name: Install and Configure LaTex
hosts: localhost
become: true
gather_facts: False
vars:
tex_live: texlive-scheme-full
tex_live_retries: 888
You are given a two-digit integer n. Return the sum of its digits.
Example
For n = 29, the output should be
solution(n) = 11.
Input/Output
[execution time limit] 3 seconds (java)
param (
[Parameter(Position=0, mandatory=$true)]
[string] $jsonConfigFilePath,
[parameter(mandatory=$false)]
[int] $debugLvl = 0,
[parameter(mandatory=$false)]
[string] $reportFilePath
)