Skip to content

Instantly share code, notes, and snippets.

View squgeim's full-sized avatar

Shreya Dahal squgeim

View GitHub Profile
@squgeim
squgeim / phone_number_validation.c
Created September 14, 2018 04:33
Check whether an input string matches the pattern provided, in this case US phone number: (###) ###-#### where # is a number.
#include<stdio.h>
#include<string.h>
#define TRUE 1
#define FALSE 0
#define ZERO '0'
#define NINE '9'
#define TOTAL_LENGTH 14
@squgeim
squgeim / vowels.c
Created September 14, 2018 04:28
Vowels Sample answer
#include<stdio.h>
#include<string.h>
#define TRUE 1
#define FALSE 0
#define LENGTH_LIMIT 1000
int is_char_vowel(char c) {
switch (c) {
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#define bool int
#define true 1
#define false 0
int get_value(char roman_number) {
switch(roman_number) {