Skip to content

Instantly share code, notes, and snippets.

View rajat1994's full-sized avatar
🏠
Working from home

Rajat Arora rajat1994

🏠
Working from home
  • Delhi
View GitHub Profile
@udacityandroid
udacityandroid / Option A
Last active March 15, 2025 14:14
Android Development for Beginners : Calculate the Price Method
/**
* Calculates the price of the order based on the current quantity.
*
* @return the price
*/
private int calculate price(int quantity {
int price = quantity * 5;
return price;
}
anonymous
anonymous / Option A
Created April 25, 2015 02:23
3 options for the layout of an activity for a quiz question
<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:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity">
@ChrisMoney
ChrisMoney / hide_show_menu_jquery.js
Last active December 26, 2021 23:46
JQuery - Show/Hide dropdown menu on hover
// Reference JQuery from Google CDN
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.js" type="text/javascript"></script>
// Markup
<ul id="jsddm">
<li><a href="#">JavaScript</a>
<ul>
<li><a href="#">Drop Down Menu</a></li>
<li><a href="#">jQuery Plugin</a></li>
<li><a href="#">Ajax Navigation</a></li>