SlideShare a Scribd company logo
1 of 16
What Makes a Good Code Example?

A Study of Programming Q&A in StackOverflow

Sayed Mehdi
Nasehi,Jonathan Sillito,
Frank Maurer, Chris Burns

Presented By: Mohammad Masudur Rahman
Contents









Why Code Example?
Thesis Statement
Stackoverflow Overview
Scores, Answer Types & Question Types
Attributes of Recognized/Good Answer
Attributes of Low-vote Answer
Important Findings & Suggestions
Limitations & Future Works
Why Code Example?
 New

technology, language, API & tools
 Learning psychology – working sample
teaches much
 Developer’s productivity
 What is a good code example? –open
question
Thesis Statement
A

good code example should include
comprehensive code as well as the text
explaining the code
 Programming Q&A site like Stackoverflow
provides more customized and helpful
answer to question rather than existing API
documentation, code repositories or search
engines
StackOverflow (http://stackoverflow.com/)
A

Programming Q&A site 1m users, 2.78m
questions, 5.77m answers and 10.5m
comments (up to March, 2012)
 Natural language search engine
 Question, tags, badges
 Answer, Editing, Comments
 Up vote, Down vote, Reputation
 89 sites: http://stackexchange.com/sites#
Scores
A

metric for Good and bad example
 Score = (Up vote – Down Vote)
 Normalized Score
 87% got <3, 13% got 10
 High score threshold 4
Answer Types
 Good

= Recognized
 Accepted = Recognized
 Unaccepted but score >=.4, then recognized
 Low vote (score <=.1)
 Long answer
Question Types
 Classification

criteria – tag/topic & what to

be solved
 Debug /Corrective
 Need-to-know
 How-to-do-it
 Seeking-different-solution
Attributes of a Recognized Answer
 Concise

code
 Using question context
 Highlighting important elements
 Step by step solutions
 Providing links to external resources
 Inline documentation
Attributes of Low Vote Answer
 Lack

of code
 Lack of explanation
 Shortcomings of solution
Answer Recognized but without Code
 Code

may not be necessary
 Link to external resources
 API Queries
Important Suggestions
 Can

the mining tools provide customized
example from code repos. based on
questioner’s expertise? –No, so make it
intelligent
 Plaintext documentation- same for all, not
helpful, so, make it wiki-like to meet user’s
needs.
Important Findings
 Customized

Answer: suits to questioner
needs better than API Docs, code
repositories or search engines.
 Customized Answer: reduces mental effort to
understand things, reduces cognitive
distance with info source
 Familiar context in solution
 Impact of question types on answer
My Observation
 Only

considered Java related Q &A
 Threshold could be changed over time,
Cohen’s kappa measurement
 Only score as a metric which may not be
feasible
 Posting time, responder’s identity, question
topic may affect the scores
Future Works
 Using

to characteristics of good code
example to we can suggest developer at
coding time with IDE
 Evaluate open-source code quality
Thank you
Questions?

More Related Content

Viewers also liked

Einführung in WAI-ARIA
Einführung in WAI-ARIAEinführung in WAI-ARIA
Einführung in WAI-ARIAStefan Walter
 
香港六合彩
香港六合彩香港六合彩
香港六合彩yahooou
 
SurfExample- Recommendation of Exception Handling Code Examples
SurfExample- Recommendation of Exception Handling Code ExamplesSurfExample- Recommendation of Exception Handling Code Examples
SurfExample- Recommendation of Exception Handling Code ExamplesMasud Rahman
 
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)Masud Rahman
 
Java RMI Detailed Tutorial
Java RMI Detailed TutorialJava RMI Detailed Tutorial
Java RMI Detailed TutorialMasud Rahman
 
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...Nokia Conversations
 
SurfClipse-- An IDE based context-aware Meta Search Engine
SurfClipse-- An IDE based context-aware Meta Search EngineSurfClipse-- An IDE based context-aware Meta Search Engine
SurfClipse-- An IDE based context-aware Meta Search EngineMasud Rahman
 
Nokia: Connecting People In New And Better Ways
Nokia: Connecting People In New And Better WaysNokia: Connecting People In New And Better Ways
Nokia: Connecting People In New And Better WaysNokia Conversations
 
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...Masud Rahman
 
SOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolSOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolMasud Rahman
 
Nokia Corporate Overview 01jul08
Nokia Corporate Overview 01jul08Nokia Corporate Overview 01jul08
Nokia Corporate Overview 01jul08Nokia Conversations
 

Viewers also liked (14)

Einführung in WAI-ARIA
Einführung in WAI-ARIAEinführung in WAI-ARIA
Einführung in WAI-ARIA
 
香港六合彩
香港六合彩香港六合彩
香港六合彩
 
SurfExample- Recommendation of Exception Handling Code Examples
SurfExample- Recommendation of Exception Handling Code ExamplesSurfExample- Recommendation of Exception Handling Code Examples
SurfExample- Recommendation of Exception Handling Code Examples
 
Ovi Maps - Ultimate routes
Ovi Maps - Ultimate routesOvi Maps - Ultimate routes
Ovi Maps - Ultimate routes
 
Smartphone360 survey
Smartphone360 surveySmartphone360 survey
Smartphone360 survey
 
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)
SurfClipse-- An IDE based context-aware Meta Search Engine (ERA Track)
 
Java RMI Detailed Tutorial
Java RMI Detailed TutorialJava RMI Detailed Tutorial
Java RMI Detailed Tutorial
 
Nokia Ovi Le Web08 11dec08
Nokia Ovi Le Web08 11dec08Nokia Ovi Le Web08 11dec08
Nokia Ovi Le Web08 11dec08
 
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...
Younghee Jung and Jan Chipchase: Presentation for Nokia Design London Studio ...
 
SurfClipse-- An IDE based context-aware Meta Search Engine
SurfClipse-- An IDE based context-aware Meta Search EngineSurfClipse-- An IDE based context-aware Meta Search Engine
SurfClipse-- An IDE based context-aware Meta Search Engine
 
Nokia: Connecting People In New And Better Ways
Nokia: Connecting People In New And Better WaysNokia: Connecting People In New And Better Ways
Nokia: Connecting People In New And Better Ways
 
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...
ContentSuggest--Recommendation of Relevant Sections from a Webpage about Erro...
 
SOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolSOAP--Simple Object Access Protocol
SOAP--Simple Object Access Protocol
 
Nokia Corporate Overview 01jul08
Nokia Corporate Overview 01jul08Nokia Corporate Overview 01jul08
Nokia Corporate Overview 01jul08
 

Similar to What Makes a Good Programming Code Example According to StackOverflow

How to find a Java developer for a successful project
How to find a Java developer for a successful projectHow to find a Java developer for a successful project
How to find a Java developer for a successful projectriyak40
 
How I Cracked the Interview to Become a Full Stack Developer.pdf
How I Cracked the Interview to Become a Full Stack Developer.pdfHow I Cracked the Interview to Become a Full Stack Developer.pdf
How I Cracked the Interview to Become a Full Stack Developer.pdfNextskill Technologies
 
Software engineer's life beyond coding
Software engineer's life beyond codingSoftware engineer's life beyond coding
Software engineer's life beyond codingNikolay Hubanov
 
Brochure - Software Development Learning Path
 Brochure - Software Development Learning Path Brochure - Software Development Learning Path
Brochure - Software Development Learning PathBoard Infinity
 
Behavior Driven Development
Behavior Driven DevelopmentBehavior Driven Development
Behavior Driven DevelopmentNETUserGroupBern
 
Automatic Identification of Informative Code in Stack Overflow Posts
Automatic Identification of Informative Code in Stack Overflow PostsAutomatic Identification of Informative Code in Stack Overflow Posts
Automatic Identification of Informative Code in Stack Overflow PostsPreetha Chatterjee
 
Casro Presentation Project And Change Management 1st June 2011
Casro Presentation   Project And Change Management 1st June 2011Casro Presentation   Project And Change Management 1st June 2011
Casro Presentation Project And Change Management 1st June 2011sam_inamdar
 
Xen Project Contributor Training - Part 1 introduction v1.0
Xen Project Contributor Training - Part 1 introduction v1.0Xen Project Contributor Training - Part 1 introduction v1.0
Xen Project Contributor Training - Part 1 introduction v1.0The Linux Foundation
 
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...University of Hawai‘i at Mānoa
 
Top 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxTop 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxSurendra Gusain
 
Top 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxTop 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxSurendra Gusain
 
6 Months Industrial Project Training in PHP Delhi/NCR
6 Months Industrial Project Training in PHP Delhi/NCR6 Months Industrial Project Training in PHP Delhi/NCR
6 Months Industrial Project Training in PHP Delhi/NCRshane99
 
Software development learning path - board infinity
Software development learning path - board infinitySoftware development learning path - board infinity
Software development learning path - board infinityBoard Infinity
 
Anti Patterns Siddhesh Lecture1 Of3
Anti Patterns Siddhesh Lecture1 Of3Anti Patterns Siddhesh Lecture1 Of3
Anti Patterns Siddhesh Lecture1 Of3Siddhesh Bhobe
 
Full Stack Software Development
Full Stack Software DevelopmentFull Stack Software Development
Full Stack Software DevelopmentLearnbay
 
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...Gabriel Rojas
 
Code Review Best Practices
Code Review Best PracticesCode Review Best Practices
Code Review Best PracticesTrisha Gee
 
Take Your API Docs from 406 Not Acceptable to 200 OK
Take Your API Docs from 406 Not Acceptable to 200 OKTake Your API Docs from 406 Not Acceptable to 200 OK
Take Your API Docs from 406 Not Acceptable to 200 OKNordic APIs
 
CSAE Redengine Presentation
CSAE Redengine PresentationCSAE Redengine Presentation
CSAE Redengine PresentationMangal11
 

Similar to What Makes a Good Programming Code Example According to StackOverflow (20)

How to find a Java developer for a successful project
How to find a Java developer for a successful projectHow to find a Java developer for a successful project
How to find a Java developer for a successful project
 
How I Cracked the Interview to Become a Full Stack Developer.pdf
How I Cracked the Interview to Become a Full Stack Developer.pdfHow I Cracked the Interview to Become a Full Stack Developer.pdf
How I Cracked the Interview to Become a Full Stack Developer.pdf
 
Software engineer's life beyond coding
Software engineer's life beyond codingSoftware engineer's life beyond coding
Software engineer's life beyond coding
 
Brochure - Software Development Learning Path
 Brochure - Software Development Learning Path Brochure - Software Development Learning Path
Brochure - Software Development Learning Path
 
Behavior Driven Development
Behavior Driven DevelopmentBehavior Driven Development
Behavior Driven Development
 
Automatic Identification of Informative Code in Stack Overflow Posts
Automatic Identification of Informative Code in Stack Overflow PostsAutomatic Identification of Informative Code in Stack Overflow Posts
Automatic Identification of Informative Code in Stack Overflow Posts
 
Casro Presentation Project And Change Management 1st June 2011
Casro Presentation   Project And Change Management 1st June 2011Casro Presentation   Project And Change Management 1st June 2011
Casro Presentation Project And Change Management 1st June 2011
 
Xen Project Contributor Training - Part 1 introduction v1.0
Xen Project Contributor Training - Part 1 introduction v1.0Xen Project Contributor Training - Part 1 introduction v1.0
Xen Project Contributor Training - Part 1 introduction v1.0
 
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...
How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics i...
 
Top 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxTop 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docx
 
Top 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docxTop 10 Interview Questions for Coding Job.docx
Top 10 Interview Questions for Coding Job.docx
 
Zeus learning
Zeus learningZeus learning
Zeus learning
 
6 Months Industrial Project Training in PHP Delhi/NCR
6 Months Industrial Project Training in PHP Delhi/NCR6 Months Industrial Project Training in PHP Delhi/NCR
6 Months Industrial Project Training in PHP Delhi/NCR
 
Software development learning path - board infinity
Software development learning path - board infinitySoftware development learning path - board infinity
Software development learning path - board infinity
 
Anti Patterns Siddhesh Lecture1 Of3
Anti Patterns Siddhesh Lecture1 Of3Anti Patterns Siddhesh Lecture1 Of3
Anti Patterns Siddhesh Lecture1 Of3
 
Full Stack Software Development
Full Stack Software DevelopmentFull Stack Software Development
Full Stack Software Development
 
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...
Prompt Engineering for AI and ML Technical Product Managers - 2023-08-21 00.5...
 
Code Review Best Practices
Code Review Best PracticesCode Review Best Practices
Code Review Best Practices
 
Take Your API Docs from 406 Not Acceptable to 200 OK
Take Your API Docs from 406 Not Acceptable to 200 OKTake Your API Docs from 406 Not Acceptable to 200 OK
Take Your API Docs from 406 Not Acceptable to 200 OK
 
CSAE Redengine Presentation
CSAE Redengine PresentationCSAE Redengine Presentation
CSAE Redengine Presentation
 

More from Masud Rahman

HereWeCode 2022: Dalhousie University
HereWeCode 2022: Dalhousie UniversityHereWeCode 2022: Dalhousie University
HereWeCode 2022: Dalhousie UniversityMasud Rahman
 
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...Masud Rahman
 
PhD Seminar - Masud Rahman, University of Saskatchewan
PhD Seminar - Masud Rahman, University of SaskatchewanPhD Seminar - Masud Rahman, University of Saskatchewan
PhD Seminar - Masud Rahman, University of SaskatchewanMasud Rahman
 
PhD proposal of Masud Rahman
PhD proposal of Masud RahmanPhD proposal of Masud Rahman
PhD proposal of Masud RahmanMasud Rahman
 
PhD Comprehensive exam of Masud Rahman
PhD Comprehensive exam of Masud RahmanPhD Comprehensive exam of Masud Rahman
PhD Comprehensive exam of Masud RahmanMasud Rahman
 
Doctoral Symposium of Masud Rahman
Doctoral Symposium of Masud RahmanDoctoral Symposium of Masud Rahman
Doctoral Symposium of Masud RahmanMasud Rahman
 
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...Masud Rahman
 
ICSE2018-Poster-Bug-Localization
ICSE2018-Poster-Bug-LocalizationICSE2018-Poster-Bug-Localization
ICSE2018-Poster-Bug-LocalizationMasud Rahman
 
CodeInsight-SCAM2015
CodeInsight-SCAM2015CodeInsight-SCAM2015
CodeInsight-SCAM2015Masud Rahman
 
RACK-Tool-ICSE2017
RACK-Tool-ICSE2017RACK-Tool-ICSE2017
RACK-Tool-ICSE2017Masud Rahman
 
QUICKAR-ASE2016-Singapore
QUICKAR-ASE2016-SingaporeQUICKAR-ASE2016-Singapore
QUICKAR-ASE2016-SingaporeMasud Rahman
 
CORRECT-ToolDemo-ASE2016
CORRECT-ToolDemo-ASE2016CORRECT-ToolDemo-ASE2016
CORRECT-ToolDemo-ASE2016Masud Rahman
 

More from Masud Rahman (20)

HereWeCode 2022: Dalhousie University
HereWeCode 2022: Dalhousie UniversityHereWeCode 2022: Dalhousie University
HereWeCode 2022: Dalhousie University
 
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...
The Forgotten Role of Search Queries in IR-based Bug Localization: An Empiric...
 
PhD Seminar - Masud Rahman, University of Saskatchewan
PhD Seminar - Masud Rahman, University of SaskatchewanPhD Seminar - Masud Rahman, University of Saskatchewan
PhD Seminar - Masud Rahman, University of Saskatchewan
 
PhD proposal of Masud Rahman
PhD proposal of Masud RahmanPhD proposal of Masud Rahman
PhD proposal of Masud Rahman
 
PhD Comprehensive exam of Masud Rahman
PhD Comprehensive exam of Masud RahmanPhD Comprehensive exam of Masud Rahman
PhD Comprehensive exam of Masud Rahman
 
Doctoral Symposium of Masud Rahman
Doctoral Symposium of Masud RahmanDoctoral Symposium of Masud Rahman
Doctoral Symposium of Masud Rahman
 
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...
Supporting Source Code Search with Context-Aware and Semantics-Driven Code Se...
 
ICSE2018-Poster-Bug-Localization
ICSE2018-Poster-Bug-LocalizationICSE2018-Poster-Bug-Localization
ICSE2018-Poster-Bug-Localization
 
MSR2017-Challenge
MSR2017-ChallengeMSR2017-Challenge
MSR2017-Challenge
 
MSR2017-RevHelper
MSR2017-RevHelperMSR2017-RevHelper
MSR2017-RevHelper
 
STRICT-SANER2017
STRICT-SANER2017STRICT-SANER2017
STRICT-SANER2017
 
MSR2015-Challenge
MSR2015-ChallengeMSR2015-Challenge
MSR2015-Challenge
 
MSR2014-Challenge
MSR2014-ChallengeMSR2014-Challenge
MSR2014-Challenge
 
CodeInsight-SCAM2015
CodeInsight-SCAM2015CodeInsight-SCAM2015
CodeInsight-SCAM2015
 
STRICT-SANER2015
STRICT-SANER2015STRICT-SANER2015
STRICT-SANER2015
 
CMPT-842-BRACK
CMPT-842-BRACKCMPT-842-BRACK
CMPT-842-BRACK
 
RACK-Tool-ICSE2017
RACK-Tool-ICSE2017RACK-Tool-ICSE2017
RACK-Tool-ICSE2017
 
RACK-SANER2016
RACK-SANER2016RACK-SANER2016
RACK-SANER2016
 
QUICKAR-ASE2016-Singapore
QUICKAR-ASE2016-SingaporeQUICKAR-ASE2016-Singapore
QUICKAR-ASE2016-Singapore
 
CORRECT-ToolDemo-ASE2016
CORRECT-ToolDemo-ASE2016CORRECT-ToolDemo-ASE2016
CORRECT-ToolDemo-ASE2016
 

Recently uploaded

Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parentsnavabharathschool99
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxAshokKarra1
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...Postal Advocate Inc.
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Celine George
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptxSherlyMaeNeri
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomnelietumpap1
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxChelloAnnAsuncion2
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxCarlos105
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfphamnguyenenglishnb
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 

Recently uploaded (20)

LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptxLEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parents
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptx
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptx
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choom
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Raw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptxRaw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptx
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 

What Makes a Good Programming Code Example According to StackOverflow

  • 1. What Makes a Good Code Example? A Study of Programming Q&A in StackOverflow Sayed Mehdi Nasehi,Jonathan Sillito, Frank Maurer, Chris Burns Presented By: Mohammad Masudur Rahman
  • 2. Contents         Why Code Example? Thesis Statement Stackoverflow Overview Scores, Answer Types & Question Types Attributes of Recognized/Good Answer Attributes of Low-vote Answer Important Findings & Suggestions Limitations & Future Works
  • 3. Why Code Example?  New technology, language, API & tools  Learning psychology – working sample teaches much  Developer’s productivity  What is a good code example? –open question
  • 4. Thesis Statement A good code example should include comprehensive code as well as the text explaining the code  Programming Q&A site like Stackoverflow provides more customized and helpful answer to question rather than existing API documentation, code repositories or search engines
  • 5. StackOverflow (http://stackoverflow.com/) A Programming Q&A site 1m users, 2.78m questions, 5.77m answers and 10.5m comments (up to March, 2012)  Natural language search engine  Question, tags, badges  Answer, Editing, Comments  Up vote, Down vote, Reputation  89 sites: http://stackexchange.com/sites#
  • 6. Scores A metric for Good and bad example  Score = (Up vote – Down Vote)  Normalized Score  87% got <3, 13% got 10  High score threshold 4
  • 7. Answer Types  Good = Recognized  Accepted = Recognized  Unaccepted but score >=.4, then recognized  Low vote (score <=.1)  Long answer
  • 8. Question Types  Classification criteria – tag/topic & what to be solved  Debug /Corrective  Need-to-know  How-to-do-it  Seeking-different-solution
  • 9. Attributes of a Recognized Answer  Concise code  Using question context  Highlighting important elements  Step by step solutions  Providing links to external resources  Inline documentation
  • 10. Attributes of Low Vote Answer  Lack of code  Lack of explanation  Shortcomings of solution
  • 11. Answer Recognized but without Code  Code may not be necessary  Link to external resources  API Queries
  • 12. Important Suggestions  Can the mining tools provide customized example from code repos. based on questioner’s expertise? –No, so make it intelligent  Plaintext documentation- same for all, not helpful, so, make it wiki-like to meet user’s needs.
  • 13. Important Findings  Customized Answer: suits to questioner needs better than API Docs, code repositories or search engines.  Customized Answer: reduces mental effort to understand things, reduces cognitive distance with info source  Familiar context in solution  Impact of question types on answer
  • 14. My Observation  Only considered Java related Q &A  Threshold could be changed over time, Cohen’s kappa measurement  Only score as a metric which may not be feasible  Posting time, responder’s identity, question topic may affect the scores
  • 15. Future Works  Using to characteristics of good code example to we can suggest developer at coding time with IDE  Evaluate open-source code quality