Profile

Cover photo
Andrew Dang (Drew)
Works at University of California - San Diego
Attends University of California, San Diego
Lives in La Jolla
340 followers|346,329 views
AboutPostsCollectionsPhotosVideos+1'sReviews

Stream

Andrew Dang (Drew)

Shared publicly  - 
 
+Kyle Barron-Kraus  This is some pretty cool #CoD stuff.
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
I entered the #Halloween  costume contest hosted by +StudyBlue  in 2013 and won a $50 amazon gift card and a #studyblue  t-shirt!

#freeswag  
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
This artist takes popular hit songs and transforms them into lullaby versions. Truly relaxing music. Music I can code to all day.

#relaxing    #music   #florenceandthemachine   #twinkletwinklelittlerockstar   #codingtunes  
1
Andrew Dang (Drew)'s profile photo
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
Won a tiki mug from #ucsdbookstore on their #funfridays contest. I need to start making a ton of tropical drinks this summer.

#freeswag #ucsd
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
1
Add a comment...
Have him in circles
340 people
Tina Tran's profile photo
Brian Thai's profile photo
Jacob Thomas's profile photo
Kate Alexia's profile photo
Kyle Barron-Kraus's profile photo
George Medeiros's profile photo
Phuong Tran's profile photo
Allied Modular Building Systems, Inc.'s profile photo
Ryan Houston's profile photo

Andrew Dang (Drew)

Shared publicly  - 
 
Put that cookie down!
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
#TIL how these sorting algorithms work.
1
Add a comment...

Andrew Dang (Drew)

commented on a video on YouTube.
Shared publicly  - 
 
Thanks the the in-depth review! Really helped my family decide to pick up the GoPro Hero4 Silver for our trip to Hawaii!
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
 
Programming challenge: Ok, so you may ask why would you program like this, but the answer is if you try this out it will force you to think in a different way that can actually benefit you longer term when writing OO code. Here is the challenge:

"In The ThoughtWorks Anthology a new book from the Pragmatic Programmers, there is a fascinating essay called “Object Calisthenics” by Jeff Bay. It’s a detailed exercise for perfecting the writing of the small routines that demonstrate characterize good OO implementations. If you have developers who need to improve their ability to write OO routines, I suggest you have a look-see at this essay. I will try to summarize Bay’s approach here. 

He suggests writing a 1000-line program with the constraints listed below. These constraints are intended to be excessively restrictive, so as to force developers out of the procedural groove. I guarantee if you apply this technique, their code will move markedly towards object orientation. The restrictions (which should be mercilessly enforced in this exercise) are:

1. Use only one level of indentation per method. If you need more than one level, you need to create a second method and call it from the first. This is one of the most important constraints in the exercise. 

2. Don’t use the ‘else’ keyword. Test for a condition with an if-statement and exit the routine if it’s not met. This prevents if-else chaining; and every routine does just one thing. You’re getting the idea.

3. Wrap all primitives and strings. This directly addresses “primitive obsession.” If you want to use an integer, you first have to create a class (even an inner class) to identify it’s true role. So zip codes are an object not an integer, for example. This makes for far clearer and more testable code.

4. Use only one dot per line. This step prevents you from reaching deeply into other objects to get at fields or methods, and thereby conceptually breaking encapsulation.

5. Don’t abbreviate names. This constraint avoids the procedural verbosity that is created by certain forms of redundancy—if you have to type the full name of a method or variable, you’re likely to spend more time thinking about its name. And you’ll avoid having objects called Order with methods entitled shipOrder(). Instead, your code will have more calls such as Order.ship().

6. Keep entities small. This means no more than 50 lines per class and no more than 10 classes per package. The 50 lines per class constraint is crucial. Not only does it force concision and keep classes focused, but it means most classes can fit on a single screen in any editor/IDE.

7. Don’t use any classes with more than two instance variables. This is perhaps the hardest constraint. Bay’s point is that with more than two instance variables, there is almost certainly a reason to subgroup some variables into a separate class. 

8. Use first-class collections. In other words, any class that contains a collection should contain no other member variables. The idea is an extension of primitive obsession. If you need a class that’s a subsumes the collection, then write it that way. 

9. Don’t use setters, getters, or properties. This is a radical approach to enforcing encapsulation. It also requires implementation of dependency injection approaches and adherence to the maxim “tell, don’t ask.” 

Taken together, these rules impose a restrictive encapsulation on developers and force thinking along OO lines. I assert than anyone writing a 1000-line project without violating these rules will rapidly become much better at OO. They can then, if they want, relax the restrictions somewhat. But as Bay points out, there’s no reason to do so. His team has just finished a 100,000-line project within these strictures."

Quote from: http://goo.gl/Wly2s4
6 comments on original post
1
Add a comment...

Andrew Dang (Drew)

Shared publicly  - 
 
Made this free tee shirt at the Samsung Booth in 2013.

#freeswag   #samsung   #android   #pride   #lgbt  
2
Add a comment...
Andrew's Collections
People
Have him in circles
340 people
Tina Tran's profile photo
Brian Thai's profile photo
Jacob Thomas's profile photo
Kate Alexia's profile photo
Kyle Barron-Kraus's profile photo
George Medeiros's profile photo
Phuong Tran's profile photo
Allied Modular Building Systems, Inc.'s profile photo
Ryan Houston's profile photo
Work
Occupation
Student
Employment
  • University of California - San Diego
    College Ambassador, 2012 - present
Places
Map of the places this user has livedMap of the places this user has livedMap of the places this user has lived
Currently
La Jolla
Previously
Los Angeles - Alhambra
Links
Other profiles
Story
Tagline
Microbiologist | Aspiring Physician | Gaymer | Tech Enthusiast | LGBT Activist |
Introduction
What I am and what I do is defined by my adventure in trying to define excellence. I live by Aristotle's quote, "We are what we repeatedly do. Excellence, therefore, is not an act but a habit."

I post about and participate in discussions on science fiction, fantasy, Star Wars, biology, android, technology, education, and photography!
Bragging rights
B.S. in Microbiology. Minors in Computer Science and Global Health Studies. Java, C++, C, Rails, Ruby, HTML, CSS, JS. Can make bomb-ass Pho. Crafted Harry Potter wands.
Education
  • University of California, San Diego
    Computer Science, 2010 - present
  • University of California, San Diego
    Global Health Studies, 2010 - present
  • University of California, San Diego
    Microbiology, 2010 - present
Basic Information
Gender
Male
Other names
Drew, Druster, Drewskii, and Gander
Apps with Google+ Sign-in
  • Blitzcrank's PoroRoundup
  • 2 Cars
Andrew Dang (Drew)'s +1's are the things they like, agree with, or want to recommend.
Google+ Photos
plus.google.com

The best photo is the one you can't wait to share with the world!

Google Play
plus.google.com

All your favorite entertainment, available anywhere you go.

University of California - San Diego
plus.google.com

University of California - San Diego hasn't shared anything on this page with you.

Google
www.google.com

Search the world's information, including webpages, images, videos and more. Google has many special features to help you find exactly what

Google at UCSD
plus.google.com

Google Student Ambassador at University of California, San Diego

Highlights: Affordable. Great milk teas. Firm and sweet bobas. Originally from the 626 area, I am in constant search for the best tea spot in San Diego. Unfortunately, SD is a desert when it comes down to good tea. From what I believe, a tea cafe claims my hard earned cash and stomach via the good old classic Black Milk tea with Honey Boba. Sharetea firmly earns this spot. Unlike most franchises, they mix the milk with freshly brewed black tea at the time of purchase. No powdery taste. Just the strong black tea with a underwhelming splash of milk. Yum. The boba is firm and sweet. Not too hard. Not too soft. Just right all the time. They aren't too shy with the fruit drinks. I recommend the Lemon Honey Tea with either Boba or Lychee Jelly. Make sure to pop a huge hole to get to the Boba easier because they include half a lemon in your drink. Also, try the Strawberry Black Tea with Lychee Jelly. Drinks are around $4.50, but their cups are pretty large compared to other places. One size only. Cons: Black Milk Teas get diluted easily and the taste gets weak. Order with less ice. There is a purchase requirement of $5 or above to use credit cards. Staff members seem pretty adamant about using the term "Pearls" instead of Boba. Drinks can take a while to make. Crowded during the evenings.
• • •
Public - a week ago
reviewed a week ago
It's okay. If you want affordable and decent Vietnamese food, Banh Mi Che Cali is a good choice. This is less of a sit down restaurant than a take out service because it's a quite small venue. It's a lot faster if you go take out. Don't expect 5 star American service. I'm a frequent of Che Cali, so it's nice that the staff know my orders right before I walk through the doors. The banh mi "sandwiches" are a lot healthier alternatives than the fast food burgers and a lot cheaper. I love ordering these for road trips or small get-togethers. I highly recommend the BBQ pork. They have boba milk teas for the cheap! 2 for $2.25. That's a steal! Don't expect it to be good as the milk teas from Cha for Tea. Pho is not the best. At most, it's decent. As another reviewer pointed, the best food is usually up on the counter. These include the deserts.
• • •
Public - 2 years ago
reviewed 2 years ago
3 reviews
Map
Map
Map
I believe the restaurant is trying create a comfortable setting for the modern Americanized Asian family. Folks from all backgrounds will find something appealing to eat from their menu. Their food ranges from pizza, pasta, and a variety of Vietnamese, Chinese, and Thai cuisine. I was able to dish out on one of their Italian pastas which I find to be very good in taste. It wasn't "excellent," but it was able to leave me with a satisfied full stomach. The atmosphere was really nice. It was very clean and modern. I have to note that there isn't much Asian to this place except the food in the menu. Great place for the kids. There are several chalk board walls where they provide chalk to their guests to draw with. The service was adequate. They were fast to serve us because there weren't many folks around to tend to at the time.
• • •
Quality: Very GoodAppeal: ExcellentService: Very Good
Public - 3 years ago
reviewed 3 years ago