Skip to content

Instantly share code, notes, and snippets.

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:gravity="center"
tools:context="com.bignerdranch.android.geoquiz.CheatActivity">
@Harvnlenny
Harvnlenny / strings.xml
Created February 12, 2016 03:03
strings for GeoQuiz Android app
<resources>
<string name="app_name">GeoQuiz</string>
<string name="next_button">Next</string>
<string name="true_button">True</string>
<string name="false_button">False</string>
<string name="correct_toast">Correct!</string>
<string name="incorrect_toast">Incorrect!</string>
<string name="action_settings">Settings</string>
<string name="question_oceans">The Pacific Ocean is larger than the Atlantic Ocean.</string>
<string name="question_mideast">The Suez Canal connects the Red Sea and the Indian Ocean.</string>
package com.example.android.justjava;
import android.os.Bundle;
import android.support.v7.app.ActionBarActivity;
import android.view.View;
import android.widget.TextView;
/**
* This app displays an order form to order coffee.
*/
@Harvnlenny
Harvnlenny / activity_main.xml
Created October 17, 2015 15:06 — forked from anonymous/activity_main.xml
RelativeLayout XML for Udacity quiz question
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="16dp">
<TextView
android:text="I’m in this corner"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
require 'minitest/autorun'
describe Array do
before do
@ary = %w(a b c d e)
@yra = ''
end
it 'it can be reversed in place' do
l = @ary.length
@Harvnlenny
Harvnlenny / blackjack
Last active August 29, 2015 14:23
Blackjack where have you been?
#!/usr/bin/evn ruby
require 'net/http'
require 'json'
BLACKJACK_API_HOST = 'pure-forest-blackjack.herokuapp.com'
class Blackjack
@http = Net::HTTP.new(BLACKJACK_API_HOST)

Front End Workshop

The Good

Breakfast was amazing. Anytime you can get unlimited bacon is a great way to start. We got lunch for free as well! Packed sandwiches allowed us to pick from many different kinds of subs. I was happy that we had a chance to pick our rooms for the workshop. I did not understand really what each room was nor did I know what would be a good fit but I was able to pick a room so that was cool. The presenters were fantastic. They were patient and had great delivery. I felt comfortable with them immediately. They walked around and made sure that everyone had a chance to get help if they needed it. Once I realized I was in over my head in the first workshop I was able to quickly move into another workshop that had some of our students in it. I started off in the animation workshop and I moved into the testing workshop. I saw a few other Iron Yard students there which made it more appealing for me to go into. I sat out the afternoon session as I just couldn't sit for another three plu

// Part I
/**
* use any of the looping methods discussed in class
*
* 1. for loop,
* 2. Array.forEach,
* 3. custom forEach
*
* to complete the following problems
class Robot
def initialize(name)
@name = name
end
def say_hi
"Hi!"
end