13:05 ET Dow -154.48 at 10309.92, Nasdaq -37.61 at 2138.44, S&P -19.130 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 0 1 100001 0 1 0 1 1 0 1 0 00 0 1 1 1 0 1 100001 0 1 1 100001 13:05 ET Dow -154.48 at 10309.92, Nasdaq -37.61 at 2138.44, S&P -19.1313:05 ET Dow -154.48 at 10309.92, Nasdaq -37.61 at 2138.44, S&P -19.13

.

.

Saturday, March 26, 2011

Congratulations Your Account Is Now Enabled for Uploads Longer than 15 Minutes

If your YouTube account remains in good standing for some extended period of time, you'll be afforded the right to upload videos longer than the usual 15 minute limitation.

Below is a screenshot of the notice one receives upon receipt.

Friday, March 25, 2011

Google Android Development - Android SDK, JAVA SE JDK, Eclipse With ADT Plugin (Android Plugin)




Code for the Back End or Calculators, Data Passing, Etc. in Java Mainly With Android Classes.
First Part of 3
========================================================

package biz.quantumsupport.tilecalculator;

import android.app.Activity;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import android.os.Bundle;


public class MyMain extends Activity {

TextView textOutTilesNeeded, txtWidthError, txtHeightError, txtAreaError;
EditText getInputW, getInputH, getInputArea;
String strWidth, strHeight, strArea, strTilesNeeded;
float fltWidth, fltHeight, fltArea, fltTilesNeeded;
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);

        txtWidthError = (EditText) findViewById(R.id.txtTileWidth);
txtHeightError = (EditText) findViewById(R.id.txtTileHeight);
txtAreaError = (EditText) findViewById(R.id.txtArea2cover);
       textOutTilesNeeded = (TextView) findViewById(R.id.lblTilesNeeded); 
       getInputW = (EditText) findViewById(R.id.txtTileWidth);
getInputH = (EditText) findViewById(R.id.txtTileHeight);
getInputArea = (EditText) findViewById(R.id.txtArea2cover);
       
Button enter = (Button) findViewById(R.id.btnEnterTile);
enter.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
strWidth = getInputW.getText().toString();
strHeight = getInputH.getText().toString();
strArea = getInputArea.getText().toString();
try{
fltWidth = Float.parseFloat(strWidth);
fltHeight = Float.parseFloat(strHeight);
fltArea = Float.parseFloat(strArea);
if(fltWidth==0 || fltHeight==0 || fltArea==0)
{
throw new Exception();
}
}
catch (Exception e) {
txtWidthError.setText("Enter");
txtHeightError.setText("All");
txtAreaError.setText("Numbers");
textOutTilesNeeded.setText("No Zeros");
return;
}
fltTilesNeeded = ((fltArea)/(fltWidth*fltHeight));
strTilesNeeded = String.valueOf(fltTilesNeeded);
textOutTilesNeeded.setText(strTilesNeeded); 
}

});
}
}


============================================================
Code for the Graphical User Interface - Android Uses Declarative Design in XML - 2nd Part of 3
============================================================


<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    >
<TextView  
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content" 
    />
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal" android:text="Tile Width"></TextView>
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal" android:text="Tile Height"></TextView>
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<EditText android:id="@+id/txtTileWidth" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal"></EditText>
<EditText android:id="@+id/txtTileHeight" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal"></EditText>
</LinearLayout>
<Button android:id="@+id/btnEnterTile" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Enter"></Button>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal" android:text="Area to Tile"></TextView>
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal" android:text="Tiles Needed"></TextView>
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<EditText android:id="@+id/txtArea2cover" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:gravity="center_horizontal"></EditText>
<TextView android:id="@+id/lblTilesNeeded" android:gravity="center_horizontal" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_weight="50" android:text=""></TextView>
</LinearLayout>
</LinearLayout>

==================================================================



Android Manifest Code - Android Development Consists of 3 Parts - Android Manifest is the 3rd of the 3 parts here. It's Unique Part to Software Development for Android - It also is in an XML format.
===================================================================

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="biz.quantumsupport.tilecalculator"
      android:versionCode="1"
      android:versionName="1.0">
    <uses-sdk android:minSdkVersion="3" />

    <application android:icon="@drawable/icon" android:label="@string/app_name">
        <activity android:name=".MyMain"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
            </activity>
    </application>
</manifest>


Monday, March 21, 2011

Java Programming for Google's Android OS

package org.example.calc;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;

public class ActionOne extends Activity  {

TextView textOutTilesNeeded, newWidth, newHeight, newArea;
EditText getInputW, getInputH, getInputArea;
float width, height, area, tilesNeeded;
String tilesNeededString, intWidth, intHeight, intArea;


@Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.tile);

textOutTilesNeeded = (TextView) findViewById(R.id.lblTilesNeeded);
newWidth = (EditText) findViewById(R.id.txtTileWidth);
newHeight = (EditText) findViewById(R.id.txtTileHeight);
newArea = (EditText) findViewById(R.id.txtArea2cover);
getInputW = (EditText) findViewById(R.id.txtTileWidth);
getInputH = (EditText) findViewById(R.id.txtTileHeight);
getInputArea = (EditText) findViewById(R.id.txtArea2cover);
Button enter = (Button) findViewById(R.id.btnEnterTile);
enter.setOnClickListener(new View.OnClickListener() {

@Override
public void onClick(View v) {
      // String string_to_float="1234.89";
      // float flt=Float.parseFloat(string_to_float);
  //    EditText et = (EditText) findViewById(R.id.entry1);
  //String hello = et.getText().toString();

intWidth = getInputW.getText().toString();
intHeight = getInputH.getText().toString();
intArea = getInputArea.getText().toString();

// TODO Auto-generated method stub
width = Float.parseFloat(intWidth);
height = Float.parseFloat(intHeight);
area = Float.parseFloat(intArea);

tilesNeeded = ((area)/(width*height));
tilesNeededString = String.valueOf(tilesNeeded);


textOutTilesNeeded.setText(tilesNeededString);


}

private float StringToFloat(String intWidth) {
// TODO Auto-generated method stub
return 0;
}
});
}
// so we can use: onPause, onCreate, etc

}

Saturday, March 19, 2011

Eclipse - R error

you can get an R error if one of your files somewhere violates the rule for files. they must be named using [a-z1-9]: you cannot use special characters, etc. for example, some acceptable names are the following: button_click1, sound54, hearingmd.

Tuesday, March 15, 2011

Some Screenshots - Android Development - Java JDK SE 6, Eclipse & Android SDK - Cell Phone Emulator Visible











How to Get Paid for Videos Posted to YouTube

1. Video regularly and post to YouTube.  Try to video things of public interest, current events (make sure you're prompt with this type of submission), instructional videos in fields in which you've industry experience, etc.
2. When posting to YouTube, make sure you fill in the tags, description, title and category listings with detail and accuracy.
3. If you get enough hits within some time frame established by YouTube, you will receive an email with an invitation to follow some steps to set up a Google AdSense account and link it to your video.
* Once your YouTube video and your Google AdSense account are linked, advertisements will be displayed next to your video. You'll get paid on a per-click basis. (And, you'll get penalized for self-clicking, so don't try that. This is checked for using unspecified (probably automated) methods).




YouTube

Dear bige143143,

Your video Shockwave Tsunami from Japan - Newport Beach, CA - View From Above might be eligible for the YouTube Partnership Program, which allows you to make money from playbacks of your video.
Making money from your video is easy. Here's how it works: First sign into your YouTube account. Then, review and complete the steps outlined here:http://www.youtube.com/ivp?v=yxk_BJC6QCE.
If your video is approved, we'll start placing ads next to the video and pay you a share of the revenue as long as you meet the program requirements.
We look forward to adding your video to the YouTube Partnership Program.
Thanks and good luck!
The YouTube Team
© 2011 YouTube, LLC
901 Cherry Ave, San Bruno, CA 94066








YouTube Partnership Program: Welcome

Congratulations on the success of your video! It's popular, and that means you may be able to make money from it by submitting it to the YouTube Partnership Program.
Before we can add your video to the program, you'll need to complete these steps:
  1. Read the tutorial
  2. Link your YouTube account to a Google AdSense account
  3. Accept the agreement
  4. Tell us more about the contents of your video
Let's get started ...


======================================================================

YouTube Partnership Program: Link Your Google AdSense Account

Your request to use an existing Google AdSense account has been submitted. You will receive an email from Google AdSense asking you to confirm this link.



==========================================================






Monday, March 14, 2011

Completed Bubble Sort Algorithm in C++





#include <iostream>
using namespace std;
#include "Vector.txt"

template <class T>
void Swap(T &a, T &b)
{
T temp = a;
a = b;
b = temp;

}

int main()
{

// which type of object for vector: int, double, float
int typeV;
std::cout << "What type of Vector do you want to act on?" << endl;
cin >> typeV;
switch (typeV)
{
case 1 :
{
Vector<int> Vint(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
int toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vint.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vint);
// Now Sort it, then prit it
int length = Vint.size();
bool swapped = false;
do
{
for(int i=0; i < (length-1) ; i++)
{
if(Vint[i]>Vint[i+1])
{
Swap<int>(Vint[i],Vint[i+1]);
cout << "There has been a swap the new Vi & V(i+1) are" << Vint[i] << "&" << Vint[i+1] << endl;
printList(Vint);
swapped = true;
}
// end if
}
// end for
}
// close 'do' block
while(swapped);

printList(Vint);
goto pass;
}
case 2 :
{
Vector<double> Vdouble(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
double toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
std::cin >> toAdd;
Vdouble.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vdouble);
// Now Sort it, then prit it
int length = Vdouble.size();
bool swapped = false;
do
{
for(int i=0; i < (length-1) ; i++)
{
if(Vdouble[i]>Vdouble[i+1])
{
Swap<double>(Vdouble[i],Vdouble[i+1]);
cout << "There has been a swap the new Vi & V(i+1) are" << Vdouble[i] << "&" << Vdouble[i+1] << endl;
printList(Vdouble);
swapped = true;
}
// end if
}
// end for
}
// close 'do' block
while(swapped);

printList(Vdouble);
goto pass;

}
case 3 :
{
Vector<float> Vfloat(0);
bool added = false;
do
{
int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
std::cin >> another;
float toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vfloat.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vfloat);
// Now Sort it, then prit it
int length = Vfloat.size();
bool swapped = false;
do
{
for(int i=0; i < (length-1) ; i++)
{
if(Vfloat[i]>Vfloat[i+1])
{
Swap<float>(Vfloat[i],Vfloat[i+1]);
cout << "There has been a swap the new Vi & V(i+1) are" << Vfloat[i] << "&" << Vfloat[i+1] << endl;
printList(Vfloat);
swapped = true;
}
// end if
}
// end for
}
// close 'do' block
while(swapped);
printList(Vfloat);
goto pass;
}

pass:




Vector<int> V1(0);
for (int i = 0; i < 10; i++)
V1.push_back(i);
printList(V1);

V1.reserve(20);
for (int i = 10; i <20; i++)
V1.push_back(i);
printList(V1);
cout << endl;

Vector<float> V2(0);
for (int i = 0; i < 10; i++)
V2.push_back((float)i + .1f);
printList(V2);
system("PAUSE");
return 0;
}
}

Sunday, March 13, 2011

#2 - Use of a Vector class in C++ : Also, demonstration of Switch, Goto, Cin, Cout, Print, etc - In Progress




#include <iostream>
using namespace std;
#include "Vector.txt"

template <class T>
void Swap(T &a, T &b)
{
T temp = a;
a = b;
b = temp;

}

int main()
{

// which type of object for vector: int, double, float
int typeV;
std::cout << "What type of Vector do you want to act on?" << endl;
cin >> typeV;
switch (typeV)
{
case 1 :
{
Vector<int> Vint(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
int toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vint.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vint);
// Now Sort it, then prit it
int length = Vint.size();
for(int i=0; i < length; i++)
{
if(Vint[i-1]>Vint[i])
Swap<int>(Vint[i-1],Vint[i]);
}
printList(Vint);
goto pass;
}
case 2 :
{
Vector<double> Vdouble(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
double toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
std::cin >> toAdd;
Vdouble.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vdouble);
goto pass;
}
case 3 :
{
Vector<float> Vfloat(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
std::cin >> another;
float toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vfloat.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vfloat);
goto pass;
}

pass:




Vector<int> V1(0);
for (int i = 0; i < 10; i++)
V1.push_back(i);
printList(V1);

V1.reserve(20);
for (int i = 10; i <20; i++)
V1.push_back(i);
printList(V1);
cout << endl;

Vector<float> V2(0);
for (int i = 0; i < 10; i++)
V2.push_back((float)i + .1f);
printList(V2);
system("PAUSE");
return 0;
}
}

Saturday, March 12, 2011

Use of a Vector class in C++ : Also, demonstration of Switch, Goto, Cin, Cout, Print, etc - In Progress

The code below is what's been constructed for the first part of an assignment: implementation of a bubble sort.

Vectors of objects (integers, double and floats) will ultimately be entered by a user in an unordered sequence.  The bubble sort will then sort the vector by ordering the vector's objects by size.

For example, if a user enters: 12, 55, 1, 5, 90; you would have (1, 5, 12, 55, 90) after the sort.

Another objective or aspect here is to calculate the amount of time (using Big-O) it takes to sort an unordered vector using different algorithms.

Incidentally, there is an infinite loop if you select 2 in the case structure.


// Ethan Castanon

#include <iostream>
using namespace std;
#include "Vector.txt"

int main()
{

// which type of object for vector: int, double, float
int typeV;
std::cout << "What type of Vector do you want to act on?" << endl;
cin >> typeV;
switch (typeV)
{
case 1 :
{
Vector<int> Vint(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
int toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vint.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vint);
goto pass;
}
case 2 :
{
Vector<double> Vdouble(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
cin >> another;
double toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
std::cin >> toAdd;
Vdouble.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vdouble);
goto pass;
}
case 3 :
{
Vector<float> Vfloat(0);
bool added = false;
do
{

int another;
std::cout << "Do you want to enter a number? Type '0' for 'N' and '1' for 'Y'" << endl;
std::cin >> another;
float toAdd;
if (another ==1)
{std::cout << "Enter an integer and press enter." << endl;
cin >> toAdd;
Vfloat.push_back(toAdd);
added = true;
}
else
added = false;
}
while(added==true);
printList(Vfloat);
goto pass;
}

pass:

// Below here is code that is not written by me (Ethan Castanon)

Vector<int> V1(0);
for (int i = 0; i < 10; i++)
V1.push_back(i);
printList(V1);

V1.reserve(20);
for (int i = 10; i <20; i++)
V1.push_back(i);
printList(V1);
cout << endl;

Vector<float> V2(0);
for (int i = 0; i < 10; i++)
V2.push_back((float)i + .1f);
printList(V2);
system("PAUSE");
return 0;
}
}

=================================================
template <typename Object>
class Vector
{
public:
// constructors
explicit Vector (int intSize = 0): theSize(intSize), 
theCapacity(intSize + SPARE_CAPACITY)
{
objects = new Object[theCapacity];
}
Vector (const Vector &rhs):objects(NULL)
{
operator=(rhs);
}
~Vector()
{
delete [] objects; 
}
const Vector & operator= (const Vector & rhs)
{
if (this != &rhs)
{
delete [] objects;
theSize = rhs.size();
theCapacity = rhs.theCapacity;
objects = new Object[capacity()];
for (int k=0; k < size(); k++)
objects[k] =rhs.objects[k];
}
return *this;
}
void resize (int newSize)
{
if (newSize > theCapacity)
reserve(newSize * 2 + 1);
theSize = newSize;
}
void reserve (int newCapacity)
{
if (newCapacity < theSize)
return;
Object *oldArray = objects;
objects = new Object[newCapacity];
for (int k=0; k < theSize; k++)
objects[k] = oldArray[k];
theCapacity = newCapacity;
delete[] oldArray;
}
Object & operator[] (int index)
{
return objects [index];
}
const Object & operator[] (int idnex) const
{
return objects [index];
}
bool empty() const
{
return size() == 0; 
}
int size() const
{
return theSize;
}
int capacity() const
{
return theCapacity;
}
void push_back(const Object &x)
{
if (theSize == theCapacity)
reserve( 2* theCapacity + 1);
objects[theSize++] = x;
}
void pop_back()
{
theSize--;
}
const Object & back() const
{
return objects [theSize - 1];
}
typedef Object* iterator;
typedef const Object* const_iterator;

iterator begin()
{
return &objects[0]; 
}
const_iterator begin() const
{
return &objects[0];
}
iterator end()
{
return &objects[size()];
}
const_iterator end() const
{
return &objects[size()];
}
enum {SPARE_CAPACITY = 16};
private:
int theSize;
int theCapacity;
Object* objects;
};
template <typename Container>
void printList (Container &vec)
{
for (Container::iterator iter = vec.begin(); 
iter != vec.end(); iter++)
cout << *iter << " ";
cout << endl;
}

T-Mobile's Bogus Unlimited Data Plan

T-Mobile offers an "Unlimited Data Plan" for $40.

This is the message I'm sent basically every month: "Free T-Mobile Message: Due to the amount of data you have used this billing cycle, your data speed will be slowed for the remainder of the cycle."

T-Mobile's Unlimited Data Plan is completely bogus.