SlideShare a Scribd company logo
CODING FOR LIBRARIANS
PART 2: CODING 101
HANDS-ON INTRODUCTION
Bohyun Kim
Associate Director, Health Sciences & Human Services Library
University of Maryland, Baltimore
ReachingAcross Illinois Library System -Webinar
Tue, May 31, 2016 1:00 PM - 2:00 PM CDT
WHY AREYOU INTERESTED IN CODING?
• Q.What do you want to be able to do once you learn how to code?
• Q. Do you have previous experience with coding, and if so what is it?
• Q. If you tried to teach yourself how to code before, what were some of the difficulties?
Flickr image: https://www.flickr.com/photos/nathansmith/4704268314
WHAT IS JAVASCRIPT?
• JavaScript is a cross-platform, object-oriented scripting language. It is a
small and lightweight language. Inside a host environment (for example, a
web browser), JavaScript can be connected to the objects of its
environment to provide programmatic control over them.
• JavaScript contains a standard library of objects, such as Array, Date, and
Math, and a core set of language elements such as operators, control
structures, and statements. Core JavaScript can be extended for a variety
of purposes by supplementing it with additional objects;
• https://developer.mozilla.org/en-
US/docs/Web/JavaScript/Guide/Introduction
JS
• Default scripting language for theWeb.
• Runs in a browser!
• Minimal dev environment setup
SET-UP
• A computer with access to the Internet
• Web browser
• Firefox
• Web Console (http://www.howtogeek.com/105320/how-to-use-
firefoxs-web-developer-tools/)
• Or, Firebug: https://addons.mozilla.org/en-
US/firefox/addon/firebug/
• Or, Chrome
• Devtools (https://developer.chrome.com/devtools)
LET’STRY RUNNING A SCRIPT!
• Open up your web browser – FF or Chrome.
• Press F-12 to open up a browser console.
FF –WEB CONSOLE
FF- FIREBUG
CHROME - DEVTOOLS
TYPETHIS IN & RUN IT!
var a = ["do", "re", "mi", "fa"];
var len = a.length;
for (var i = 0; i < len; i++) {
console.log(a[i]);
}
• Result should look like this. FF above. Chrome below.
SUCCESS? : )
Don’t worry yet about what it means.
We will take a look again at the end of this workshop.
And it will all make sense then!
1.VARIABLES
• 4+10
• 2*5
• var a=24/4;
• a
• console.log(a);
• var b=“Catherine”;
• console.log(b);
• console.log(c);
• a+b
• a+3
VARIABLES & OPERATORS
• http://www.w3schools.com/js/js_variables.asp
• http://www.w3schools.com/js/js_operators.asp
2. DATATYPES
• Number
• String
• Array
• Object
• Boolean
DATATYPES
• http://www.w3schools.com/js/js_datatypes.asp
3. FUNCTIONS
Coding 101: A hands-on introduction
FUNCTIONS
• http://www.w3schools.com/js/js_functions.asp
4. ARRAYS
• http://www.w3schools.com/js/js_arrays.asp
5. ARRAY METHODS
• http://www.w3schools.com/js
/js_array_methods.asp
MORE ARRAY METHODS
DIDWE
RUN OUT OFTIME
YET? : )
6. FOR LOOP
var a = ["do", "re", "mi", "fa"];
var len = a.length;
for (var i = 0; i < len; i++) {
console.log(a[i]);
}
FOR LOOP
• http://www.w3schools.com/js/js_loop_for.asp
7. STRING
• http://www.w3schools.com/js/js_strings.asp
8. METHODS FORTHE STRING OBJECT
• http://www.w3schools.com/js/js_string_methods.asp
CODE EXAMPLE
https://htmlpreview.github.io/?https://github.com/jcmeloni/H
TMLCSSJSAiO-code/blob/master/04/dateandtime.html
Coding 101: A hands-on introduction
MORE CODE EXAMPLES BY ME
WITH EXPLANATION
• The simplest AJAX: writing your own code (1)
http://www.bohyunkim.net/blog/archives/2186
• More APIs: writing your own code (2) http://www.bohyunkim.net/blog/archives/2219
• Playing with JavaScript and JQuery – the Ebook link HTML string generator and the
EZproxy bookmarklet generator http://www.bohyunkim.net/blog/archives/255
• Fear no Longer Regular Expressions http://www.bohyunkim.net/blog/archives/2595
• Using the StripeAPI to Collect Library Fines by Accepting Online Payments
http://www.bohyunkim.net/blog/archives/3009
• More simple code examples at https://github.com/bohyunkim/examples
TIPS
• Don’t be discouraged or frustrated.You are teaching yourself a language.
• Be persistent and realistic.
• Set small goals that solve real-life problems.
• Form or join a study group & find like-minded folks!
• Comment your code and document since you will forget what you have
learned and made.
THANKYOU!

More Related Content

PPTX
Why Care About Coding?
PPTX
Research for MATC Classes
PPTX
Psych 440 Information Literacy Class
PDF
Connecting in the Middle with Technology & Resources
PPT
Rockland BOCES School Library System
PPTX
Research Management Tools
PDF
Pundit at the Final DM2E event
Why Care About Coding?
Research for MATC Classes
Psych 440 Information Literacy Class
Connecting in the Middle with Technology & Resources
Rockland BOCES School Library System
Research Management Tools
Pundit at the Final DM2E event

What's hot (16)

PPTX
Text to speech and word predicition
PPTX
That's Information Literacy?: Using Technology to Engage Students
PPTX
Referencing methods and approaches
PPTX
Media literacy search
PPTX
Electronic Books
PPT
eBooks for Everyone: Inclusive Publishing
PPTX
Text to speech and word predicition
PPT
Internet Literacy Workshop
PDF
(Ab)using Identifiers: Indiscernibility of Identity
PPS
Gr8composerpaper09
PPT
Integrating Inquiry: Student Centered Approaches for Inspiring Lifelong Lear...
PPTX
Fa12 w200-w3-part5
PPTX
Organizing Research
PPTX
Loj library orientation
PDF
Learning Activities in Personal Learning Environment
PDF
Open Sesame (and other open movements)
Text to speech and word predicition
That's Information Literacy?: Using Technology to Engage Students
Referencing methods and approaches
Media literacy search
Electronic Books
eBooks for Everyone: Inclusive Publishing
Text to speech and word predicition
Internet Literacy Workshop
(Ab)using Identifiers: Indiscernibility of Identity
Gr8composerpaper09
Integrating Inquiry: Student Centered Approaches for Inspiring Lifelong Lear...
Fa12 w200-w3-part5
Organizing Research
Loj library orientation
Learning Activities in Personal Learning Environment
Open Sesame (and other open movements)
Ad

Viewers also liked (17)

PPTX
Applying Gamification to Higher Education and Libraries
PPTX
IT Budgeting with Scarcity
PPTX
2013- A Pathway to Success for Students who Present with Social Skill Needs
PPTX
Building a Makerspace: Where to Start
PPTX
Improving Your Library's Mobile Services
PDF
Etiquette & Personal Grooming
PPTX
The Social Dimension of Technology
PPTX
Strategically UX Oriented with Personas
PPTX
Work Smarter, Not Harder: Relationship Building 2.0 at the Alliance Theatre, ...
PPT
GROOMING FOR SUCCESS
PPT
Identifying & Harnessing the Power of Networking Part One
PPT
I am a personal brand
PPT
Personal Branding Presentation
PDF
Personal Branding To Stand Out & Differentiate Yourself
PDF
Personal Branding Maps
PDF
Personal branding - do it yourself
PDF
Brand You : Personal Branding
Applying Gamification to Higher Education and Libraries
IT Budgeting with Scarcity
2013- A Pathway to Success for Students who Present with Social Skill Needs
Building a Makerspace: Where to Start
Improving Your Library's Mobile Services
Etiquette & Personal Grooming
The Social Dimension of Technology
Strategically UX Oriented with Personas
Work Smarter, Not Harder: Relationship Building 2.0 at the Alliance Theatre, ...
GROOMING FOR SUCCESS
Identifying & Harnessing the Power of Networking Part One
I am a personal brand
Personal Branding Presentation
Personal Branding To Stand Out & Differentiate Yourself
Personal Branding Maps
Personal branding - do it yourself
Brand You : Personal Branding
Ad

Similar to Coding 101: A hands-on introduction (20)

PPTX
Introduction to Coding
PDF
Leveling Up at JavaScript
PDF
Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"
PPTX
Getting Started with Coding
PPTX
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
PDF
Add-On Development: EE Expects that Every Developer will do his Duty
PDF
presentation
PDF
presentation
PDF
Add-On Development: EE Expects that Every Developer will do his Duty
PPTX
Craft of coding
PPTX
iOS Beginners Lesson 1
PDF
High quality Front-End
PDF
50 Shades of Fail KScope16
PDF
Killing Shark-Riding Dinosaurs with ORM
PPT
IWMW 2002: Portals and CMS:" Why You Need Them Both
PDF
Value streammapping cascadiait2014-mceniry
PDF
Test Automation for Packaged Systems: Yes, You Can!
PDF
Webinar: Fusion 3.1 - What's New
PPTX
Apresentação - Minicurso de Introdução a Python, Data Science e Machine Learning
PPTX
Introduction to C#.pptx for all BSIT students
Introduction to Coding
Leveling Up at JavaScript
Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"
Getting Started with Coding
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
Add-On Development: EE Expects that Every Developer will do his Duty
presentation
presentation
Add-On Development: EE Expects that Every Developer will do his Duty
Craft of coding
iOS Beginners Lesson 1
High quality Front-End
50 Shades of Fail KScope16
Killing Shark-Riding Dinosaurs with ORM
IWMW 2002: Portals and CMS:" Why You Need Them Both
Value streammapping cascadiait2014-mceniry
Test Automation for Packaged Systems: Yes, You Can!
Webinar: Fusion 3.1 - What's New
Apresentação - Minicurso de Introdução a Python, Data Science e Machine Learning
Introduction to C#.pptx for all BSIT students

More from Bohyun Kim (20)

PDF
Exploring Machine Learning for Libraries and Archives: Present and Future
PDF
New Technologies of the Fourth Industrial Revolution: AI, IoT, Robotics, and ...
PDF
Practical Considerations for Open Infrastructure
PDF
AI for Libraries
PDF
The Potential and Challenges of Today's AI
PDF
Robots: What Could Go Wrong? What Could Go Right?
PDF
AI & Us: Are We Intelligent Machines?
PDF
Blockchain: The New Technology and Its Applications for Libraries
PDF
Machine Intelligence and Moral Decision-Making
PDF
Impact of Artificial Intelligence (AI) on Libraries
PDF
Taking on a New Leadership Challenge: Student-Focused Learning in Artificial ...
PDF
Moving Forward with Digital Disruption: A Right Mindset
PDF
 Blockchain Overview: Possibilities and Issues
PDF
AI Lab at a Library? Why Artificial Intelligence Matters & What Libraries Can Do
PDF
A Pedagogical Approach to Web Scale Discovery User Interface
PDF
From Virtual Reality to Blockchain: Current and Emerging Tech Trends
PDF
Interdisciplinary Learning through Libraries on Artificial Intelligence
PPTX
Facing Change: Tweak or Transform?
PPTX
Innovating Together: the UX of Discovery
PPTX
Cleaning Up the Mess: Modernizing Your Dev Team’s Outdated Workflow
Exploring Machine Learning for Libraries and Archives: Present and Future
New Technologies of the Fourth Industrial Revolution: AI, IoT, Robotics, and ...
Practical Considerations for Open Infrastructure
AI for Libraries
The Potential and Challenges of Today's AI
Robots: What Could Go Wrong? What Could Go Right?
AI & Us: Are We Intelligent Machines?
Blockchain: The New Technology and Its Applications for Libraries
Machine Intelligence and Moral Decision-Making
Impact of Artificial Intelligence (AI) on Libraries
Taking on a New Leadership Challenge: Student-Focused Learning in Artificial ...
Moving Forward with Digital Disruption: A Right Mindset
 Blockchain Overview: Possibilities and Issues
AI Lab at a Library? Why Artificial Intelligence Matters & What Libraries Can Do
A Pedagogical Approach to Web Scale Discovery User Interface
From Virtual Reality to Blockchain: Current and Emerging Tech Trends
Interdisciplinary Learning through Libraries on Artificial Intelligence
Facing Change: Tweak or Transform?
Innovating Together: the UX of Discovery
Cleaning Up the Mess: Modernizing Your Dev Team’s Outdated Workflow

Recently uploaded (20)

PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
Tartificialntelligence_presentation.pptx
PDF
Electronic commerce courselecture one. Pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Spectral efficient network and resource selection model in 5G networks
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PPTX
Spectroscopy.pptx food analysis technology
PPTX
SOPHOS-XG Firewall Administrator PPT.pptx
PDF
Empathic Computing: Creating Shared Understanding
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
Tartificialntelligence_presentation.pptx
Electronic commerce courselecture one. Pdf
Unlocking AI with Model Context Protocol (MCP)
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
NewMind AI Weekly Chronicles - August'25-Week II
Spectral efficient network and resource selection model in 5G networks
MYSQL Presentation for SQL database connectivity
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Encapsulation_ Review paper, used for researhc scholars
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Network Security Unit 5.pdf for BCA BBA.
Programs and apps: productivity, graphics, security and other tools
The Rise and Fall of 3GPP – Time for a Sabbatical?
20250228 LYD VKU AI Blended-Learning.pptx
Spectroscopy.pptx food analysis technology
SOPHOS-XG Firewall Administrator PPT.pptx
Empathic Computing: Creating Shared Understanding
Build a system with the filesystem maintained by OSTree @ COSCUP 2025

Coding 101: A hands-on introduction