Skip to content

Instantly share code, notes, and snippets.

View JohnPhamous's full-sized avatar
🚀
Hopefully not blowing anything up

John Pham JohnPhamous

🚀
Hopefully not blowing anything up
View GitHub Profile
#include <iostream>
using namespace std;
int main() {
char userChar;
int userInt;
int count = 1;
cout << "Enter a character: ";
#include <iostream>
#include <vector>
#include <cmath>
using namespace std;
// Mart Molle's Square Sorting algorithm
// Time Complexity: O(n^2), Theta(n^2), Omega(n)
// Space Complexity: O(1)
template <typename T>
#include <iostream>
using namespace std;
int main() {
cout << "Enter a number between -50 and 50: " << endl;
int userInt;
cin >> userInt;
if (userInt > 50 && userInt < -50) {
#include <iostream>
using namespace std;
// Rules:
// User will enter in 4 numbers: a, b, c, d
// a > b, b < c, c = d
int main() {
int num1,
num2,
#include <iostream>
#include <string>
using namespace std;
bool cmp1(string a, string b) {
return a == b;
}
bool cmp2(string a, string b) {
for (int i = 0; i < a.size(); i++) {
#include <iostream>
using namespace std;
int main() {
cout << "Enter a number from 1 to 100: ";
int userInput;
cin >> userInput;
bool triggered = false;
import string
private_e = 37
private_n = 77
encrypted_message = []
decrypted_message = []
for m in encrypted_message:
d = (m ** private_e) % private_n
<html>
<head>
<title>Todo List</title>
<style>
html {
background-color: red;
color: white;
}
#appTitle {
color: pink;
<html>
<head>
<title>Todo List</title>
<style>
#appTitle {
color: pink;
font-family: Arial;
background-color: hotpink;
}
</style>
// Written by John Pham
// [email protected]
#include <iostream>
// to use rand() and srand()
#include <stdlib.h>
// to use vectors
#include <vector>