SlideShare a Scribd company logo
Wisdom for Programmers

Sung-Kook Han
http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html
The RedMonk Programming Language Rankings: September 2012

1.JavaScript
2.Java
3.PHP
4.Python
5.Ruby
6.C#
7.C++
8.C
9.Objective-C
10.Shell
11.Perl
12.Scala
13.Haskell
14.ASP
15.Assembly
16.ActionScript
17.R
18.Visual Basic
19.CoffeeScript
20.Groovy

http://redmonk.com/sogrady/2012/09/12/language-rankings-9-12/#ixzz26XhGIOrn
FORTRAN 77

Assembler

COBOL
APL
C
Objective-C
XML

PASCAL

BASIC
LISP
C++

C#

PROLOG
ML

JAVA
RDF/RDFS

OWL








void HandleStuff( CORP_DATA & inputRec, int crntQtr, EMP_DATA empRec, double
& estimRevenue, double ytdRevenue, int screenX, int screenY, COLOR_TYPE &
newColor, COLOR_TYPE & prevColor, StatusType & status, int expenseType )
{




int i;
for ( i = 0; i < 100; i++ ) {
 inputRec.revenue[i] = 0;


inputRec.expense[i] = corpExpense [crntQtr ][ i ];

}
UpdateCorpDatabase( empRec );

estimRevenue = ytdRevenue * 4.0 / (double) crntQtr;
newColor = prevColor;

status = SUCCESS;
if ( expenseType == 1 ) {
for ( i = 0; i < 12; i++ ) 
 profit[i] = revenue[i] - expense.type1[i];
}
else if ( expenseType == 2 ) { 
profit[i] = revenue[i] - expense.type2[i];
}
else if ( expenseType == 3 ) 
profit[i] = revenue[i] - expense.type3[i];
}
선서
나는
프로그램 고수들을 나의 멘토로 모시고,
그들의 지혜를 경청하고 실천하여,
프로그래밍의 본질을 깨우쳐

프로그래밍의 전설적 고수가 되고자 합니다...
Define the problem completely.
If you don't understand it, you can't program it.
Without a good problem definition,
you might put effort into solving the wrong problem.
Be sure you know what you’re aiming at before you shoot.
Think first, Program lately.
Put the Mouse Down and Step Away from the Keyboard..
Throw away the keyboard !!
Fire, Aim, Ready ??
Look before leap.
Draw Diagrams !!
Think twice, code once.
Design first, then code.
Use the top-down approach.
Look at the whole picture !!
Draw Diagrams !!
Keep It Simple, Stupid! (KISS)
Keep it short and simple.
Occam's razor !!
Everything should be made as simple as possible,
but no simpler. - Albert Einstein
Don’t Repeat Yourself. (DRY)
Once And Only Once !!
Duplication is Evil (DIE).
Insanity: doing the same thing over and over again
and expecting different results.
Read The Fine Magazine. (RTFM)
Read The Fine Manual.
Read books, magazines, blogs, twitter feeds, and web sites.
Always try to work with a mentor.
If you can't find a mentor, consider moving on.

Go to conferences. Listen to podcasts.
Continuous Learning…
Understand the Art behind the Language.
Understand the philosophy of programming language.
Understand the culture of your programming language !!

Be aware of the specific strengths and weaknesses of the
language you’re using.
Choose the right programming language.
Don’t limit your programming thinking
only to the concepts that are supported
automatically by your language.
Divide and Conquer !!
Modern software is inherently complex.
Minimize the amount of essential complexity that anyone’s
brain has to deal with at any one time.
Don't Be Afraid to Break Things.
Keep accidental complexity from needlessly proliferating.
Modeling.
Without good software modeling, you may have the right problem
but the wrong solution.
It may be impossible to have successful construction.
Code is design.
Model-driven architecture: MVC Model
GoF: Design Patterns
Abstraction !!
Keep the level of the abstraction !!
Encapsulate all in the side .
Hide Secrets (Information Hiding).
Localize them.
Avoiding global data.
Single Responsibility.
Single Responsibility Principle:
a class should have one, and only one, reason to change.
Every piece of knowledge must have a single, unambiguous,
authoritative representation within a system.
-- Andy Hunt and Dave Thomas in The Pragmatic Programmer.

Single Source of Truth in model-driven architectures.
Defensive Programming
A clever person solves a problem. A wise person avoids it.
– Einstein
Be careful for Exceptions, Errors, Warnings,…
Make it fail-safe before you make it better.
Protecting Your Program From Invalid Inputs.
garbage in, nothing out / garbage in, error message out /
no garbage allowed in
Build Your Own Assertion Mechanism.
Automate Your Coding Standard.
Pretty Print (PP).
Style !! Layout !! Format !!
Hungarian notation by Charles Simonyi.
Use (naming) conventions.
Iterate, Repeatedly, Again and Again
Programming is neither fully an art nor fully a science.
As it’s typically practiced, it’s a “craft” that’s somewhere
between art and science. -- McConnell 2004
A first attempt might produce a solution that works,
but it’s unlikely to produce the best solution.

Don't be afraid to start over
Programmer(programming)
Comments are not evil.
Provide good documentation.

Don't just echo code in comments
- make every comment meaningful.
Choose Your Tools with Care.
Right Programming Language and Right Tools !!
Design Tools // Source-Code Tools // Executable-Code Tools
Tool-Oriented Environments
Building Your Own Programming Tools
Discipline is the best tool.
Ask "What Would the User Do?"
You are not the User.
Use case analysis.
The User is the King. The user is Dummy.
User-Friendly.
Pieces of the advice
 Never assume the computer assumes anything.
 Don't patch bad code - rewrite it.
 Make sure all variables are initialized before use.
 Choose a data representation which makes the program simple.
 Be sparing with temporary variables.
 Parenthesize to avoid ambiguity.
 Avoid side effects
 Use library functions.
 Choose a data representation which makes the program simple.
 Test input for plausibility and validity.
Be Open Mind !!
Refuse to pretend you’re an expert when you’re not.
Readily admit your mistakes.
Get excited about programming !!
Open, Share, Communicate, and Cooperate !!
.
References.
Very Simple Quiz: What’s wrong ?
// Compute roots of a quadratic equation.
// This code assumes that (b*b-4*a*c) is positive.
temp = Sqrt( b*b - 4*a*c );
root[O] = ( -b + temp ) / ( 2 * a );
root[1] = ( -b - temp ) / ( 2 * a );
...
// swap the roots
temp = root[0];
root[0] = root[1];
root[1] = temp;
for ( int i = 0; i < numPayCodes; i++ ) {
for ( int j = 0; j < 12; j++ ) {
for ( int k = 0; k < numDivisions; k++ ) {
sum = sum + transaction[ j ][ i ][ k ];
}
}
}

More Related Content

What's hot

Language Workbenches
Language WorkbenchesLanguage Workbenches
Language Workbenches
Mikhail Barash
 
Script writing (2)
Script writing (2)Script writing (2)
Script writing (2)lenteraide
 
10 steps to becoming a professional software engineer
10 steps to becoming a professional software engineer10 steps to becoming a professional software engineer
10 steps to becoming a professional software engineerJimmy Sorensen
 
DSLs: what, why, how
DSLs: what, why, howDSLs: what, why, how
DSLs: what, why, how
Mikhail Barash
 
Clean Code and Common Engineering Practices
Clean Code and Common Engineering PracticesClean Code and Common Engineering Practices
Clean Code and Common Engineering Practices
Ruth Sperer
 
JetBrains MPS
JetBrains MPSJetBrains MPS
Intro flash cards
Intro flash cardsIntro flash cards
Intro flash cardslorhow58
 
Intro flash cards
Intro flash cardsIntro flash cards
Intro flash cardslorhow58
 
Learn java theory presentation
Learn java theory presentationLearn java theory presentation
Learn java theory presentation
Mark John Lado, MIT
 
Pair programming and pair training
Pair programming and pair trainingPair programming and pair training
Pair programming and pair training
Roberto Bettazzoni
 
Design concerns for concrete syntax
Design concerns for concrete syntaxDesign concerns for concrete syntax
Design concerns for concrete syntax
Mikhail Barash
 
What is Coding
What is CodingWhat is Coding
What is Coding
RoboGarden
 
DSL development
DSL developmentDSL development
DSL development
Mikhail Barash
 
10 Things You Probably Should Have Learned With Your Computer Science Degree....
10 Things You Probably Should Have Learned With Your Computer Science Degree....10 Things You Probably Should Have Learned With Your Computer Science Degree....
10 Things You Probably Should Have Learned With Your Computer Science Degree....
New Relic
 
Programming paradigm and web programming
Programming paradigm and web programmingProgramming paradigm and web programming
Programming paradigm and web programming
Mohammad Kamrul Hasan
 
5 reasons why NetBeans should be in every developers toolkit (devfest2014)
5 reasons why NetBeans should be in every developers toolkit (devfest2014)5 reasons why NetBeans should be in every developers toolkit (devfest2014)
5 reasons why NetBeans should be in every developers toolkit (devfest2014)
idrsolutions
 
Zoo of domain-specific languages
Zoo of domain-specific languagesZoo of domain-specific languages
Zoo of domain-specific languages
Mikhail Barash
 
What Is Coding And Why Should You Learn It?
What Is Coding And Why Should You Learn It?What Is Coding And Why Should You Learn It?
What Is Coding And Why Should You Learn It?
Syed Hassan Raza
 

What's hot (18)

Language Workbenches
Language WorkbenchesLanguage Workbenches
Language Workbenches
 
Script writing (2)
Script writing (2)Script writing (2)
Script writing (2)
 
10 steps to becoming a professional software engineer
10 steps to becoming a professional software engineer10 steps to becoming a professional software engineer
10 steps to becoming a professional software engineer
 
DSLs: what, why, how
DSLs: what, why, howDSLs: what, why, how
DSLs: what, why, how
 
Clean Code and Common Engineering Practices
Clean Code and Common Engineering PracticesClean Code and Common Engineering Practices
Clean Code and Common Engineering Practices
 
JetBrains MPS
JetBrains MPSJetBrains MPS
JetBrains MPS
 
Intro flash cards
Intro flash cardsIntro flash cards
Intro flash cards
 
Intro flash cards
Intro flash cardsIntro flash cards
Intro flash cards
 
Learn java theory presentation
Learn java theory presentationLearn java theory presentation
Learn java theory presentation
 
Pair programming and pair training
Pair programming and pair trainingPair programming and pair training
Pair programming and pair training
 
Design concerns for concrete syntax
Design concerns for concrete syntaxDesign concerns for concrete syntax
Design concerns for concrete syntax
 
What is Coding
What is CodingWhat is Coding
What is Coding
 
DSL development
DSL developmentDSL development
DSL development
 
10 Things You Probably Should Have Learned With Your Computer Science Degree....
10 Things You Probably Should Have Learned With Your Computer Science Degree....10 Things You Probably Should Have Learned With Your Computer Science Degree....
10 Things You Probably Should Have Learned With Your Computer Science Degree....
 
Programming paradigm and web programming
Programming paradigm and web programmingProgramming paradigm and web programming
Programming paradigm and web programming
 
5 reasons why NetBeans should be in every developers toolkit (devfest2014)
5 reasons why NetBeans should be in every developers toolkit (devfest2014)5 reasons why NetBeans should be in every developers toolkit (devfest2014)
5 reasons why NetBeans should be in every developers toolkit (devfest2014)
 
Zoo of domain-specific languages
Zoo of domain-specific languagesZoo of domain-specific languages
Zoo of domain-specific languages
 
What Is Coding And Why Should You Learn It?
What Is Coding And Why Should You Learn It?What Is Coding And Why Should You Learn It?
What Is Coding And Why Should You Learn It?
 

Viewers also liked

Presentacion3
Presentacion3Presentacion3
Presentacion3zirbruno
 
How to innovate your ICT business
How to innovate your ICT businessHow to innovate your ICT business
How to innovate your ICT business
Won Kwang University
 
Idean_LeanResearch_Jan2014_FINAL
Idean_LeanResearch_Jan2014_FINALIdean_LeanResearch_Jan2014_FINAL
Idean_LeanResearch_Jan2014_FINALLiya James
 
GA_LeanResearch
GA_LeanResearchGA_LeanResearch
GA_LeanResearchLiya James
 
Hp Uiuc Part2
Hp Uiuc Part2Hp Uiuc Part2
Hp Uiuc Part2zirbruno
 
Presentacion1
Presentacion1Presentacion1
Presentacion1zirbruno
 
D I G I T A L J U K E C O R P O R A T I O N Finish
D I G I T A L  J U K E  C O R P O R A T I O N FinishD I G I T A L  J U K E  C O R P O R A T I O N Finish
D I G I T A L J U K E C O R P O R A T I O N Finishlmiloje2
 
Sws Han
Sws HanSws Han
Killer Presentation
Killer PresentationKiller Presentation
Killer Presentation
Won Kwang University
 
Layers of Smalltalk Application
Layers of Smalltalk ApplicationLayers of Smalltalk Application
Layers of Smalltalk Applicationspeludner
 
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
X User
 
Van Catalogiseren Naar Metadatabeheer131107
Van  Catalogiseren Naar Metadatabeheer131107Van  Catalogiseren Naar Metadatabeheer131107
Van Catalogiseren Naar Metadatabeheer131107
guestf040ad
 
Semantic Technology: State of the arts and Trends
Semantic Technology: State of the arts and TrendsSemantic Technology: State of the arts and Trends
Semantic Technology: State of the arts and Trends
Won Kwang University
 
Lib0604
Lib0604Lib0604
Ontology Dev
Ontology DevOntology Dev
Ontology Dev
Won Kwang University
 
4th Industrial Revolution and Restoration of Humanity
4th Industrial Revolution and Restoration of Humanity4th Industrial Revolution and Restoration of Humanity
4th Industrial Revolution and Restoration of Humanity
Won Kwang University
 

Viewers also liked (17)

Presentacion3
Presentacion3Presentacion3
Presentacion3
 
How to innovate your ICT business
How to innovate your ICT businessHow to innovate your ICT business
How to innovate your ICT business
 
Idean_LeanResearch_Jan2014_FINAL
Idean_LeanResearch_Jan2014_FINALIdean_LeanResearch_Jan2014_FINAL
Idean_LeanResearch_Jan2014_FINAL
 
GA_LeanResearch
GA_LeanResearchGA_LeanResearch
GA_LeanResearch
 
Hp Uiuc Part2
Hp Uiuc Part2Hp Uiuc Part2
Hp Uiuc Part2
 
Presentation1
Presentation1Presentation1
Presentation1
 
Presentacion1
Presentacion1Presentacion1
Presentacion1
 
D I G I T A L J U K E C O R P O R A T I O N Finish
D I G I T A L  J U K E  C O R P O R A T I O N FinishD I G I T A L  J U K E  C O R P O R A T I O N Finish
D I G I T A L J U K E C O R P O R A T I O N Finish
 
Sws Han
Sws HanSws Han
Sws Han
 
Killer Presentation
Killer PresentationKiller Presentation
Killer Presentation
 
Layers of Smalltalk Application
Layers of Smalltalk ApplicationLayers of Smalltalk Application
Layers of Smalltalk Application
 
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
How to create_a_simple_java_web_service_and_publish_it_on_netbeans_7
 
Van Catalogiseren Naar Metadatabeheer131107
Van  Catalogiseren Naar Metadatabeheer131107Van  Catalogiseren Naar Metadatabeheer131107
Van Catalogiseren Naar Metadatabeheer131107
 
Semantic Technology: State of the arts and Trends
Semantic Technology: State of the arts and TrendsSemantic Technology: State of the arts and Trends
Semantic Technology: State of the arts and Trends
 
Lib0604
Lib0604Lib0604
Lib0604
 
Ontology Dev
Ontology DevOntology Dev
Ontology Dev
 
4th Industrial Revolution and Restoration of Humanity
4th Industrial Revolution and Restoration of Humanity4th Industrial Revolution and Restoration of Humanity
4th Industrial Revolution and Restoration of Humanity
 

Similar to Good programming

The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms Programming
Juan J. Merelo
 
Cinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsCinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patterns
Steven Smith
 
Culture And Aesthetic Revisited
Culture And Aesthetic RevisitedCulture And Aesthetic Revisited
Culture And Aesthetic RevisitedAdam Keys
 
Cs8392 u1-1-oop intro
Cs8392 u1-1-oop introCs8392 u1-1-oop intro
Cs8392 u1-1-oop intro
Rajasekaran S
 
Rrw02 Week 1 Assignment
Rrw02 Week 1 AssignmentRrw02 Week 1 Assignment
Rrw02 Week 1 Assignment
Sheri Elliott
 
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Arnauld Loyer
 
Essential c notes singh projects
Essential c notes singh projectsEssential c notes singh projects
Essential c notes singh projects
SINGH PROJECTS
 
Mastering python lesson1
Mastering python lesson1Mastering python lesson1
Mastering python lesson1
Ruth Marvin
 
On being a professional software developer
On being a professional software developerOn being a professional software developer
On being a professional software developer
Anton Kirillov
 
Documentation for developers
Documentation for developersDocumentation for developers
Documentation for developers
Michael Marotta
 
The Good, the Bad and the Ugly things to do with android
The Good, the Bad and the Ugly things to do with androidThe Good, the Bad and the Ugly things to do with android
The Good, the Bad and the Ugly things to do with android
Stanojko Markovik
 
Evolving as a professional software developer
Evolving as a professional software developerEvolving as a professional software developer
Evolving as a professional software developer
Anton Kirillov
 
How to code
How to codeHow to code
How to code
Shishir Sharma
 
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
RootedCON
 
Take the Smalltalk Red Pill
Take the Smalltalk Red PillTake the Smalltalk Red Pill
Take the Smalltalk Red Pill
OSOCO
 

Similar to Good programming (20)

The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms Programming
 
Cinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsCinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patterns
 
Culture And Aesthetic Revisited
Culture And Aesthetic RevisitedCulture And Aesthetic Revisited
Culture And Aesthetic Revisited
 
Cs8392 u1-1-oop intro
Cs8392 u1-1-oop introCs8392 u1-1-oop intro
Cs8392 u1-1-oop intro
 
Rrw02 Week 1 Assignment
Rrw02 Week 1 AssignmentRrw02 Week 1 Assignment
Rrw02 Week 1 Assignment
 
Os Goodger
Os GoodgerOs Goodger
Os Goodger
 
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
 
Essential c
Essential cEssential c
Essential c
 
Essential c notes singh projects
Essential c notes singh projectsEssential c notes singh projects
Essential c notes singh projects
 
Essential c
Essential cEssential c
Essential c
 
Essential c
Essential cEssential c
Essential c
 
Essential c
Essential cEssential c
Essential c
 
Mastering python lesson1
Mastering python lesson1Mastering python lesson1
Mastering python lesson1
 
On being a professional software developer
On being a professional software developerOn being a professional software developer
On being a professional software developer
 
Documentation for developers
Documentation for developersDocumentation for developers
Documentation for developers
 
The Good, the Bad and the Ugly things to do with android
The Good, the Bad and the Ugly things to do with androidThe Good, the Bad and the Ugly things to do with android
The Good, the Bad and the Ugly things to do with android
 
Evolving as a professional software developer
Evolving as a professional software developerEvolving as a professional software developer
Evolving as a professional software developer
 
How to code
How to codeHow to code
How to code
 
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
Joxean Koret - Interactive Static Analysis Tools for Vulnerability Discovery ...
 
Take the Smalltalk Red Pill
Take the Smalltalk Red PillTake the Smalltalk Red Pill
Take the Smalltalk Red Pill
 

More from Won Kwang University

Prospects, concerns, and response strategies for the post-AI world
Prospects, concerns, and response strategies for the post-AI worldProspects, concerns, and response strategies for the post-AI world
Prospects, concerns, and response strategies for the post-AI world
Won Kwang University
 
Digital_Healthcare_and_ICT.pdf
Digital_Healthcare_and_ICT.pdfDigital_Healthcare_and_ICT.pdf
Digital_Healthcare_and_ICT.pdf
Won Kwang University
 
humanities and liberal arts in the age of Artificial Intelligence
humanities and liberal arts in the age of Artificial Intelligencehumanities and liberal arts in the age of Artificial Intelligence
humanities and liberal arts in the age of Artificial Intelligence
Won Kwang University
 
스마트 교수학습법
스마트 교수학습법스마트 교수학습법
스마트 교수학습법
Won Kwang University
 
[배포]4차 교육혁신
[배포]4차 교육혁신[배포]4차 교육혁신
[배포]4차 교육혁신
Won Kwang University
 
Tutorial kcc-2011
Tutorial kcc-2011Tutorial kcc-2011
Tutorial kcc-2011
Won Kwang University
 
Onto Sem
Onto SemOnto Sem
Semantic Search Trend
Semantic Search TrendSemantic Search Trend
Semantic Search Trend
Won Kwang University
 

More from Won Kwang University (9)

Prospects, concerns, and response strategies for the post-AI world
Prospects, concerns, and response strategies for the post-AI worldProspects, concerns, and response strategies for the post-AI world
Prospects, concerns, and response strategies for the post-AI world
 
Digital_Healthcare_and_ICT.pdf
Digital_Healthcare_and_ICT.pdfDigital_Healthcare_and_ICT.pdf
Digital_Healthcare_and_ICT.pdf
 
humanities and liberal arts in the age of Artificial Intelligence
humanities and liberal arts in the age of Artificial Intelligencehumanities and liberal arts in the age of Artificial Intelligence
humanities and liberal arts in the age of Artificial Intelligence
 
스마트 교수학습법
스마트 교수학습법스마트 교수학습법
스마트 교수학습법
 
[배포]4차 교육혁신
[배포]4차 교육혁신[배포]4차 교육혁신
[배포]4차 교육혁신
 
Tutorial kcc-2011
Tutorial kcc-2011Tutorial kcc-2011
Tutorial kcc-2011
 
Future Library
Future LibraryFuture Library
Future Library
 
Onto Sem
Onto SemOnto Sem
Onto Sem
 
Semantic Search Trend
Semantic Search TrendSemantic Search Trend
Semantic Search Trend
 

Recently uploaded

The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
RinaMondal9
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
sonjaschweigert1
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
Peter Spielvogel
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 

Recently uploaded (20)

The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 

Good programming

  • 2.
  • 3.
  • 5. The RedMonk Programming Language Rankings: September 2012 1.JavaScript 2.Java 3.PHP 4.Python 5.Ruby 6.C# 7.C++ 8.C 9.Objective-C 10.Shell 11.Perl 12.Scala 13.Haskell 14.ASP 15.Assembly 16.ActionScript 17.R 18.Visual Basic 19.CoffeeScript 20.Groovy http://redmonk.com/sogrady/2012/09/12/language-rankings-9-12/#ixzz26XhGIOrn
  • 6.
  • 8.     void HandleStuff( CORP_DATA & inputRec, int crntQtr, EMP_DATA empRec, double & estimRevenue, double ytdRevenue, int screenX, int screenY, COLOR_TYPE & newColor, COLOR_TYPE & prevColor, StatusType & status, int expenseType ) {     int i; for ( i = 0; i < 100; i++ ) {  inputRec.revenue[i] = 0;   inputRec.expense[i] = corpExpense [crntQtr ][ i ];  } UpdateCorpDatabase( empRec );  estimRevenue = ytdRevenue * 4.0 / (double) crntQtr; newColor = prevColor;  status = SUCCESS; if ( expenseType == 1 ) { for ( i = 0; i < 12; i++ )   profit[i] = revenue[i] - expense.type1[i]; } else if ( expenseType == 2 ) {  profit[i] = revenue[i] - expense.type2[i]; } else if ( expenseType == 3 )  profit[i] = revenue[i] - expense.type3[i]; }
  • 9. 선서 나는 프로그램 고수들을 나의 멘토로 모시고, 그들의 지혜를 경청하고 실천하여, 프로그래밍의 본질을 깨우쳐 프로그래밍의 전설적 고수가 되고자 합니다...
  • 10. Define the problem completely. If you don't understand it, you can't program it. Without a good problem definition, you might put effort into solving the wrong problem. Be sure you know what you’re aiming at before you shoot.
  • 11. Think first, Program lately. Put the Mouse Down and Step Away from the Keyboard.. Throw away the keyboard !! Fire, Aim, Ready ?? Look before leap. Draw Diagrams !! Think twice, code once. Design first, then code.
  • 12. Use the top-down approach. Look at the whole picture !! Draw Diagrams !!
  • 13. Keep It Simple, Stupid! (KISS) Keep it short and simple. Occam's razor !! Everything should be made as simple as possible, but no simpler. - Albert Einstein
  • 14. Don’t Repeat Yourself. (DRY) Once And Only Once !! Duplication is Evil (DIE). Insanity: doing the same thing over and over again and expecting different results.
  • 15. Read The Fine Magazine. (RTFM) Read The Fine Manual. Read books, magazines, blogs, twitter feeds, and web sites. Always try to work with a mentor. If you can't find a mentor, consider moving on. Go to conferences. Listen to podcasts. Continuous Learning…
  • 16. Understand the Art behind the Language. Understand the philosophy of programming language. Understand the culture of your programming language !! Be aware of the specific strengths and weaknesses of the language you’re using. Choose the right programming language. Don’t limit your programming thinking only to the concepts that are supported automatically by your language.
  • 17. Divide and Conquer !! Modern software is inherently complex. Minimize the amount of essential complexity that anyone’s brain has to deal with at any one time. Don't Be Afraid to Break Things. Keep accidental complexity from needlessly proliferating.
  • 18. Modeling. Without good software modeling, you may have the right problem but the wrong solution. It may be impossible to have successful construction. Code is design. Model-driven architecture: MVC Model GoF: Design Patterns
  • 19. Abstraction !! Keep the level of the abstraction !! Encapsulate all in the side . Hide Secrets (Information Hiding). Localize them. Avoiding global data.
  • 20. Single Responsibility. Single Responsibility Principle: a class should have one, and only one, reason to change. Every piece of knowledge must have a single, unambiguous, authoritative representation within a system. -- Andy Hunt and Dave Thomas in The Pragmatic Programmer. Single Source of Truth in model-driven architectures.
  • 21. Defensive Programming A clever person solves a problem. A wise person avoids it. – Einstein Be careful for Exceptions, Errors, Warnings,… Make it fail-safe before you make it better. Protecting Your Program From Invalid Inputs. garbage in, nothing out / garbage in, error message out / no garbage allowed in Build Your Own Assertion Mechanism.
  • 22. Automate Your Coding Standard. Pretty Print (PP). Style !! Layout !! Format !! Hungarian notation by Charles Simonyi. Use (naming) conventions.
  • 23. Iterate, Repeatedly, Again and Again Programming is neither fully an art nor fully a science. As it’s typically practiced, it’s a “craft” that’s somewhere between art and science. -- McConnell 2004 A first attempt might produce a solution that works, but it’s unlikely to produce the best solution. Don't be afraid to start over
  • 24. Programmer(programming) Comments are not evil. Provide good documentation. Don't just echo code in comments - make every comment meaningful.
  • 25. Choose Your Tools with Care. Right Programming Language and Right Tools !! Design Tools // Source-Code Tools // Executable-Code Tools Tool-Oriented Environments Building Your Own Programming Tools Discipline is the best tool.
  • 26. Ask "What Would the User Do?" You are not the User. Use case analysis. The User is the King. The user is Dummy. User-Friendly.
  • 27. Pieces of the advice  Never assume the computer assumes anything.  Don't patch bad code - rewrite it.  Make sure all variables are initialized before use.  Choose a data representation which makes the program simple.  Be sparing with temporary variables.  Parenthesize to avoid ambiguity.  Avoid side effects  Use library functions.  Choose a data representation which makes the program simple.  Test input for plausibility and validity.
  • 28. Be Open Mind !! Refuse to pretend you’re an expert when you’re not. Readily admit your mistakes. Get excited about programming !! Open, Share, Communicate, and Cooperate !! .
  • 30. Very Simple Quiz: What’s wrong ? // Compute roots of a quadratic equation. // This code assumes that (b*b-4*a*c) is positive. temp = Sqrt( b*b - 4*a*c ); root[O] = ( -b + temp ) / ( 2 * a ); root[1] = ( -b - temp ) / ( 2 * a ); ... // swap the roots temp = root[0]; root[0] = root[1]; root[1] = temp; for ( int i = 0; i < numPayCodes; i++ ) { for ( int j = 0; j < 12; j++ ) { for ( int k = 0; k < numDivisions; k++ ) { sum = sum + transaction[ j ][ i ][ k ]; } } }