Skip to content

Instantly share code, notes, and snippets.

View mbcarruthers's full-sized avatar
🥗

McCain Carruthers mbcarruthers

🥗
View GitHub Profile
(function() {
var a = b = 3;
})();
console.log("a defined " + (typeof a != 'undefined'));
console.log("b defined " + (typeof b != 'undefined'));
#include <iostream>
#include <vector>
using namespace std;
int main () {
int chooseAnother;
bool isTrue = true;
while(isTrue == true) {
let array1 = [1,2,3,9];
let array2 = [1,2,4,4];
//make a program that goes through each of these arrays and can
//return to you whether 2 numbers add to equal 8
for(let i = 0;i<array2.length;i++) {
for(let j = 0;j < array2.length;j++) {
if(array2[i] + array2[j] === 8) {
console.log(array2[i] + ' and ' + array2[j] +' add to equal 8');
let array1 = [1,2,3,9];
let array2 = [1,2,4,4];
//make a program that goes through each of these arrays and can
//return to you whether 2 numbers add to equal 8
for(let i = 0;i<array2.length;i++) {
for(let j = 0;j < array2.length;j++) {
if(array2[i] + array2[j] === 8) {
console.log(array2[i] + ' and ' + array2[j] +' add to equal 8');
let array1 = [1,2,3,9];
let array2 = [1,2,4,4];
//make a program that goes through each of these arrays and can
//return to you whether 2 numbers add to equal 8
for(let i = 0;i<array2.length;i++) {
for(let j = 0;j < array2.length;j++) {
if(array2[i] + array2[j] === 8) {
console.log(array2[i] + ' and ' + array2[j] +' add to equal 8');
let array1 = [1,2,3,9];
let array2 = [1,2,4,4];
//make a program that goes through each of these arrays and can
//return to you whether 2 numbers add to equal 8
for(let i = 0;i<array2.length;i++) {
for(let j = 0;j < array2.length;j++) {
if(array2[i] + array2[j] === 8) {
console.log(array2[i] + ' and ' + array2[j] +' add to equal 8');
#include <iostream>
#include <string>
using namespace std;
int main () {
class person = new class();
#include <iostream>
#include <string>
using namespace std;
int main () {