Our team is switching from CodeIgniter to Laravel as PHP framework. I'm currently in the learning process of using this framework and I can say that if you used Ruby On Rails before, you will see some similarity on both. I also like it's Blade Templating System that makes the view more manageable.
Monday, December 23, 2013
Friday, October 18, 2013
SQL Commands Cheat Sheets
ABORT -- abort the current transaction ALTER DATABASE -- change a database ALTER GROUP -- add users to a group or remove users from a gro...
Saturday, August 31, 2013
Coderbyte: Second GreatLow (Ruby)
PROBLEM
Have the function SecondGreatLow(arr) take the array of numbers stored in arr
and return the second lowest and second greatest numbers, respectively, separated by a space. For example: if arr contains [7, 7, 12, 98, 106] the output should be 12 98. The array will not be empty and will contain at least 2 numbers. It can get tricky if there's just two numbers!.
Coderbyte: Letter Count I (Ruby)
PROBLEM
Have the function LetterCountI(str) take the str
parameter being passed and return the first word with the greatest
number of repeated letters. For example: "Today, is the greatest day
ever!" should return greatest because it has 2 e's (and 2 t's) and it comes before ever which also has 2 e's. If there are no words with repeating letters return -1. Words will be separated by spaces.
Coderbyte: Array Addition I (Ruby)
PROBLEM
Have the function ArrayAdditionI(arr) take the array of numbers stored in arr and return the string true if any combination of numbers in the array can be added up to equal the largest number in the array, otherwise return the string false. For example: if arr contains [4, 6, 23, 10, 1, 3] the output should return true because 4 + 6 + 10 + 3 = 23. The array will not be empty, will not contain all the same elements, and may contain negative numbers
Have the function ArrayAdditionI(arr) take the array of numbers stored in arr and return the string true if any combination of numbers in the array can be added up to equal the largest number in the array, otherwise return the string false. For example: if arr contains [4, 6, 23, 10, 1, 3] the output should return true because 4 + 6 + 10 + 3 = 23. The array will not be empty, will not contain all the same elements, and may contain negative numbers
Coderbyte: Arith Geo (Ruby)
PROBLEM
Have the function ArithGeo(arr) take the array of numbers stored in arr
and return the string "Arithmetic" if the sequence follows an arithmetic pattern or return "Geometric" if it follows a geometric pattern. If the sequence doesn't follow either pattern return -1.
An arithmetic sequence is one where the difference between each of the
numbers is consistent, where as in a geometric sequence, each term after
the first is multiplied by some constant or common ratio. Arithmetic
example: [2, 4, 6, 8] and Geometric example: [2, 6, 18, 54]. Negative
numbers may be entered as parameters, 0 will not be entered, and no
array will contain all the same elements.
Coderbyte: Palindrome (Ruby)
PROBLEM
Have the function Palindrome(str) take the str
parameter being passed and return the string true if the parameter is a palindrome, (the string is the same forward as it is backward) otherwise return the string false. For example: "racecar" is also "racecar" backwards. Punctuation and numbers will not be part of the string.
Coderbyte: Ex Oh (Ruby)
PROBLEM
Have the function ExOh(str) take the str parameter being passed and return the string true if there is an equal number of x's and o's, otherwise return the string false. Only these two letters will be entered in the string, no punctuation or numbers. For example: if str is "xooxxxxooxo" then the output should return false because there are 6 x's and 5 o's.
Friday, August 23, 2013
Coderbyte: Word Count (Ruby)
PROBLEM
Have the function WordCount(str) take the str
string parameter being passed and return the number of words the string contains (ie. "Never eat shredded wheat" would return 4). Words will be separated by single spaces.
Coderbyte: Vowel Count (Ruby)
PROBLEM
Have the function VowelCount(str) take the str
string parameter being passed and return the number of vowels the string contains (ie. "All cows eat grass" would return 5). Do not count y as a vowel for this challenge.
Wednesday, August 21, 2013
Coderbyte: AB Check (Ruby)
PROBLEM
Have the function ABCheck(str) take the str parameter being passed and return the string true if the characters a and b are separated by exactly 3 places anywhere in the string at least once (ie. "lane borrowed" would result in true because there is exactly three characters between a and b). Otherwise return the string false.
Coderbyte: Alphabet Soup (Ruby)
PROBLEM
Have the function AlphabetSoup(str) take the str string parameter being passed and return the string with the letters in alphabetical order (ie. hello becomes ehllo). Assume numbers and punctuation symbols will not be included in the string.
Coderbyte: Time Convert (Ruby)
PROBLEM
Have the function TimeConvert(num) take the num
parameter being passed and return the number of hours and minutes the parameter converts to (ie. if num = 63 then the output should be 1:3). Separate the number of hours and minutes with a colon.
Monday, August 19, 2013
GitHub Windows: Commit failed: Failed To Create A New Commit
PROBLEM
While testing some functionality of GitHub Windows, an error occurred while committing. To be exact, the error displayed is Commit failed: Failed to create a new commit. We tested it on different projects and the commit was successful.
Coderbyte: Check Nums (Ruby)
PROBLEM
Have the function CheckNums(num1,num2) take both parameters being passed and return the string true if num2 is greater than num1, otherwise return the string false. If the parameter values are equal to each other then return the string -1.
Coderbyte: Simple Symbols (Ruby)
PROBLEM
Have the function SimpleSymbols(str) take the str parameter being passed and determine if it is an acceptable sequence by either returning the string true or false. The str parameter will be composed of + and = symbols with several letters between them (ie. ++d+===+c++==a) and for the string to be true each letter must be surrounded by a + symbol. So the string to the left would be false. The string will not be empty and will have at least one letter.
Coderbyte: Letter Capitalize (Ruby)
PROBLEM
Have the function LetterCapitalize(str) take the str parameter being passed and capitalize the first letter of each word. Words will be separated by only one space.
Coderbyte: Simple Adding (Ruby)
PROBLEM
Have the function SimpleAdding(num) add up all the numbers from 1 to num. For the test cases, the parameter num will be any number from 1 to 1000.
Sunday, August 18, 2013
Coderbyte: Letter Changes (Ruby)
PROBLEM
Have the function LongestWord(sen) take the sen
parameter being passed and return the largest word in the string. If
there are two or more words that are the same length, return the first
word from the string with that length. Ignore punctuation and assume sen will not be empty.
Coderbyte: Longest Word (Ruby)
PROBLEM
Have the function LongestWord(sen) take the sen
parameter being passed and return the largest word in the string. If
there are two or more words that are the same length, return the first
word from the string with that length. Ignore punctuation and assume sen will not be empty.