Categories

## HackerRank – 30 Days of Code – Day 7: Arrays – Ruby Program

Objective Today, we’re learning about the Array data structure. Check out the Tutorial tab for learning materials and an instructional video! Task Given an array, A, of N integers, print A’s elements in reverse order as a single line of space-separated numbers. Input Format The first line contains an integer, N(the size of our array). […]

Categories

## HackerRank – 30 Days of Code – Day 6: Let’s Review – Ruby Program

Objective Today we’re expanding our knowledge of Strings and combining it with what we’ve already learned about loops. Check out the Tutorial tab for learning materials and an instructional video! Task Given a string, S, of length N that is indexed from 0 to N-1, print its even-indexed and odd-indexed characters as 2 space-separated strings […]

Categories

## HackerRank – 30 Days of Code – Day 5: Loops – Ruby Program

Objective In this challenge, we’re going to use loops to help us do some simple math. Check out the Tutorial tab to learn more. Task Given an integer, n, print its first 10 multiples. Each multiple n x i (where 1<=i<=10) should be printed on a new line in the form: n x i = […]

Categories

## HackerRank – 30 Days of Code – Day 4: Class vs. Instance – Ruby Program

Objective In this challenge, we’re going to learn about the difference between a class and an instance; because this is an Object Oriented concept, it’s only enabled in certain languages. Check out the Tutorial tab for learning materials and an instructional video! Task Write a Person class with an instance variable, age, and a constructor […]

Categories

## HackerRank – 30 Days of Code – Day 3: Intro to Conditional Statements – Ruby Program

Objective In this challenge, we’re getting started with conditional statements. Check out the Tutorial tab for learning materials and an instructional video! Task Given an integer, n, perform the following conditional actions: If n is odd, print Weird If n is even and in the inclusive range of 2 to 5, print Not Weird If […]

Categories

## How to test CCAvenue Payment Gateway in localhost? (Avoid Error Code: 10002 Merchant Authentication failed)

In this tutorial, I am going to discuss how to test a CCAvenue payment gateway on your local system. Why this tutorial? To test CCAvenue in localhost. To avoid issues on the Live website. CCAvenue is one of the leading payment gateway providers in India, though their documentation is not up to the industry standard. […]

Categories

## Best Practices to Ensure Transaction Integrity in CCAvenue Payment Gateway

The following Best Practices are guidelines only. It is recommended that you consult with security experts with experience in your web environment to ensure that your security is appropriate for your needs. 1. Use a unique order number for each transaction attempt CCAvenueÂ system does not validate your order number for uniqueness. If you send the […]

Categories

## Complete list of CCAvenue Response code with description

CCAvenue Response Codes Name Description Type (length) order_id Unique ID sent by the merchant at the time of initiating the transaction. Alphanumeric (30) tracking_id Unique payment reference number generated by CCAvenue for each order. Numeric (12) bank_ref_no Reference number generated by the bank for the transaction. Alphanumeric order_status Status of the transaction. Alphabets (15) Success […]

Categories

## Complete List of CCAvenue Error Codes with reason

CCAvenue Error Code Error Code Short Message Long Message Correcting this Error 10002 Authentication Failed Merchant Authentication failed This error can be caused by an incorrect merchant ID, an incorrect access code, or if the order originates from an unregistered URL. Make sure that all three of these values are correct. For your security, CCAvenue […]

Categories

## How to choose default driver in Capybara?

Capybara uses the same DSL to drive a variety of browser and headless drivers. The default drivers for Capybara is RACK WebDriver. Common Capybara WebDrivers 1. RACK (default) 2. Selenium 3. Capybara-webKit 4. Poltergeist (headless) Syntax for selecting drivers Capybara.default_driver = :[driver name] example: Capybara.default_driver = :rack_test Capybara.default_driver = :selenium You can change the default […]