Your SlideShare is downloading. ×
  • Like
CleanCode chapter2
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Now you can save presentations on your phone or tablet

Available for both IPhone and Android

Text the download link to your phone

Standard text messaging rates apply

CleanCode chapter2

  • 612 views
Published

 

Published in Technology , Sports
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
612
On SlideShare
0
From Embeds
0
Number of Embeds
2

Actions

Shares
Downloads
1
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Clean code11 11 5
  • 2. 11 11 5
  • 3. int d; // d int elapsedTimeInDays; int daysSinceCreation; int daysSinceModification; int fileAgeInDays;11 11 5
  • 4. public List<int []> getThem() { List<int[]> list1 = new ArrayList<int []>(); for ( int [] x : theList) if (x[0] == 4) list1.add(x); return list1; }11 11 5
  • 5. 11 11 5
  • 6. public List<Cell> getFlaggedCells() { List<Cell> flaggedCells = new ArrayList<Cell>(); for (Cell cell : gameBoard) if (cell.isFlagged()) flaggedCells.add(cell); return flaggedCells; }11 11 5
  • 7. hp, aix, sco Unix (hypotenuse)11 11 5
  • 8. List accountList List accounts accountGroup11 11 5
  • 9. ’L’ ’O’ 1 011 11 5
  • 10. (a1, a2 ... aN) public static void copyChars (char a1[], char a2[]){ for (int i = 0; i < a1.length(); i++) a2[i] = a1[i]; } a1 source, a2 destination11 11 5
  • 11. ProductInfo ProductData NameString Name Customer CustomerObject11 11 5
  • 12. private Date genymdhmsl private Date modymdhms private final String pszqint = “102”; private Date generationTimestamp; private Date modificationTimestamp; private final String recordId = “102”;11 11 5
  • 13. MAX_CLASSES_PER_STUDENT grep11 11 5
  • 14. Manager, Processor, Data, Info11 11 5
  • 15. JavaBean11 11 5
  • 16. 11 11 5
  • 17. fetch, retrieve, get DeviceManager ProtocolController manager controller11 11 5
  • 18. add Insert11 11 5
  • 19. 11 11 5
  • 20. 11 11 5
  • 21. (Gas Station Deluxe) GSD11 11 5
  • 22. 11 11 5