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 "dynamicarray.h" | |
using namespace std; | |
DynamicArray::DynamicArray() { | |
DynamicArray::DynamicArray(5); | |
} | |
DynamicArray::DynamicArray(int initSize) { | |
size = initSize; |
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
/* Queue - Circular Array implementation in C++*/ | |
#include<iostream> | |
using namespace std; | |
#define MAX_SIZE 101 //maximum size of the array that will store Queue. | |
// Creating a class named Queue. | |
class Queue | |
{ | |
private: | |
int A[MAX_SIZE]; |
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
let state = [ "AK - Alaska", | |
"AL - Alabama", | |
"AR - Arkansas", | |
"AS - American Samoa", | |
"AZ - Arizona", | |
"CA - California", | |
"CO - Colorado", | |
"CT - Connecticut", | |
"DC - District of Columbia", | |
"DE - Delaware", |
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
var card_number = "" | |
func make_random_number(num:Int)->[Int]{ | |
var result = [Int]() | |
for _ in 0...num { | |
result.append(Int(arc4random_uniform(9))) | |
} | |
return result | |
} | |
func luhn_algorithm(){ |
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 random | |
credit_card_number = "" | |
def make_random_number(number_of_element): | |
random_numbers = [] | |
for i in range(number_of_element): | |
random_numbers.append(random.randint(0, 9)) | |
return random_numbers |
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
function isChatMessage(message) { | |
if (message.__x_isSentByMe) { | |
return false; | |
} | |
if (message.__x_isNotification) { | |
return false; | |
} | |
if (!message.__x_isUserCreatedType) { | |
return false; | |
} |
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
// | |
// Config.swift | |
// Analytics | |
// | |
public protocol AnalyticsConfig { | |
static var analyticsKey: String { get } | |
static var appVersion: String { get } | |
} |