[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-515443-105":59,"doc-detail-515443-en":130,"doc-similar-515443":288},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":123,"head_meta":125,"extra_data":127,"updated_unix":129},105,"en","learn-python-the-hard-way-third-edition-introduction","Learn Python The Hard Way - Third Edition - Introduction","","Learn Python the hard way presents an instructional, exercise-driven path to building working software while learning computer programming fundamentals. The book is structured around short, understandable exercises thoroughly tested with real students to improve learning outcomes, supplemented by an accompanying video that walks through each exercise’s code. It uses humor and inside jokes to support engagement, includes guidance for reading and writing, attention to detail, and multiple beginner exercises that progressively cover setup, programs, comments, numbers, and variables.",{"@graph":69,"@context":122},[70,84,105],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":30,"@type":76,"position":81},"https://docshare.wps.com/document/technology/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/learn-python-the-hard-way-third-edition-introduction/515443/",{"url":83,"name":65,"@type":85,"image":86,"author":91,"headline":65,"publisher":94,"fileFormat":97,"inLanguage":63,"description":67,"dateModified":98,"datePublished":99,"encodingFormat":97,"isAccessibleForFree":100,"interactionStatistic":101},"DigitalDocument",{"url":87,"@type":88,"width":89,"height":90},"https://docshare.wps.com/thumbnails/learn-python-the-hard-way-third-edition-introduction/515443.png","ImageObject",300,407,{"name":92,"@type":93},"LangkahRina","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-11-25","2026-10-06",true,{"@type":102,"interactionType":103,"userInteractionCount":44},"InteractionCounter",{"@type":104},"ViewAction",{"@type":106,"mainEntity":107},"FAQPage",[108,114,118],{"name":109,"@type":110,"acceptedAnswer":111},"How is the learning approach designed in Learn Python the Hard Way?","Question",{"text":112,"@type":113},"The book teaches through short, understandable exercises that guide readers step by step to create working software, supported by an accompanying video walkthrough.","Answer",{"name":115,"@type":110,"acceptedAnswer":116},"What kinds of practice materials does the book include?",{"text":117,"@type":113},"Each exercise includes sections such as “What You Should See,” “Study Drills,” and “Common Student Questions,” helping readers validate results and deepen understanding.",{"name":119,"@type":110,"acceptedAnswer":120},"What topics are covered in the early exercises?",{"text":121,"@type":113},"The opening exercises cover the setup across operating systems, writing a first program, comments, numbers and math, variables and names, and printing with more variables.","https://schema.org",{"og:url":83,"og:type":124,"og:title":65,"og:site_name":95,"og:description":67},"article",{"robots":126,"canonical":83},"index,follow",{"doc_id":128,"site_id":62},515443,1791417908,{"code":4,"msg":5,"data":131},{"doc_id":128,"user_id":132,"nickname":92,"user_avatar":133,"doc_module":4,"category_id":29,"category_name":30,"doc_title":65,"doc_description":67,"doc_content":134,"file_id":135,"file_url":136,"file_type":137,"file_size":138,"view_count":44,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":139,"language":140,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":141,"faqs":142,"seo_title":143,"seo_description":67,"update_tm":144,"read_time":145,"preview_page_count":146,"preview_urls":147},962090893776,"https://ap-avatar.wpscdn.com/davatar_155a257f0dc6eb9ab79c44ca47cae57d","LEARN PYTHON THE HARD WAY  \nThird Edition  \nZed Shaw’s Hard Way Series  \nVisit [informit.com/hardway](informit.com/hardway for a complete)[ for a complete](informit.com/hardway for a complete) list of available publications.  \nZed Shaw’s Hard Way Series emphasizes instruction and making things as  \nthe best way to get started in many computer science topics. Each book in the series is designed around short, understandable exercises that take you through a course of instruction that creates working software. All exercises are thoroughly tested to verify they work with real students, thus increasing your chance of success. The accompanying video walks you through the code in each exercise. Zed adds a bit of humor and inside jokes to make you laugh while you’re learning.  \nMake sure to connect with us! [inform it. com/socialconnect](inform it. com/socialconnect)  \nLEARN PYTHON THE HARD WAY  \nA Very Simple Introduction to the Terrifyingly Beautiful World of Computers and Code  \nThird Edition  \nZedA. Shaw  \nUpper Saddle River, NJ • Boston • Indianapolis • San Francisco New York • Toronto • Montreal • London • Munich • Paris • Madrid Capetown • Sydney • Tokyo • Singapore • Mexico City  \nMany of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and the publisher was aware of a trademark claim, the designations have been printed with initial capital letters or in all capitals.  \nThe author and publisher have taken care in the preparation of this book, but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for incidental or consequential damages in connection with or arising out of the use of the information or programs contained herein.  \nThe publisher offers excellent discounts on this book when ordered in quantity for bulk purchases or special sales, which may include electronic versions and/or custom covers and content particular to your business, training goals, marketing focus, and branding interests. For more information, please contact:  \nU.S. Corporate and Government Sales  \n(800) 382-3419  \n[corpsales@pearsontechgroup.com](corpsales@pearsontechgroup.com)  \nFor sales outside the United States, please contact:  \nInternational Sales  \n[international@pearson.com](international@pearson.com)[ ](international@pearson.com)Visit us on the Web: [informit.com/aw](informit.com/aw)  \nLibrary of Congress Cataloging-in-Publication Data Shaw, Zed.  \nLearn Python the hard way : a very simple introduction to the terrifyingly beautiful world of computers and code / Zed A. Shaw.—Third edition.  \npages cm Includes index.  \nISBN 978-0-321-88491-6 (paperback : alkaline paper)  \n1. Python (Computer program language) 2. Python (Computer program language)—Problems, exercises, etc. 3. Computer programming—Problems, exercises, etc. I. Title.  \nQA76 .73. P98S53 2014 005.13'3—dc23  \n2013029738  \nCopyright © 2014 Zed A. Shaw  \nAll rights reserved. Printed in the United States of America. This publication is protected by copyright, and permission must be obtained from the publisher prior to any prohibited reproduction, storage in a retrieval system, or transmission in any form or by any means, electronic, mechanical, photocopying, recording, or likewise. To obtain permission to use material from this work, please submit a written request to Pearson Education, Inc., Permissions Department, One Lake Street, Upper Saddle River, New Jersey 07458, or you may fax your request to (201) 236-3290.  \nISBN-13: 978-0-321-88491-6  \nISBN-10: 0-321-88491-4  \nText printed in the United States on recycled paper at RR Donnelley in Crawfordsville, Indiana. First printing, September 2013  \nV  \nContents  \nPreface ..................................................... 1  \nAcknowledgments ......................................... 1  \nThe Hard Way Is Easier ...................................... 1  \nRead","cbCaidHhf0ikcImK","https://ap.wps.com/l/cbCaidHhf0ikcImK","pdf",2688111,306,"English","# Preface\n## A very simple introduction\n# Exercise 0 The Setup\n## Mac OSX\n## Windows\n## Linux\n# Exercise 1 A Good First Program\n# Exercise 2 Comments and Pound Characters\n# Exercise 3 Numbers and Math\n# Exercise 4 Variables and Names\n# Exercise 5 More Variables and Printing","[{\"question\":\"How is the learning approach designed in Learn Python the Hard Way?\",\"answer\":\"The book teaches through short, understandable exercises that guide readers step by step to create working software, supported by an accompanying video walkthrough.\"},{\"question\":\"What kinds of practice materials does the book include?\",\"answer\":\"Each exercise includes sections such as “What You Should See,” “Study Drills,” and “Common Student Questions,” helping readers validate results and deepen understanding.\"},{\"question\":\"What topics are covered in the early exercises?\",\"answer\":\"The opening exercises cover the setup across operating systems, writing a first program, comments, numbers and math, variables and names, and printing with more variables.\"}]","Learn Python The Hard Way - Third Edition - Introduction | PDF",1791314047,771,31,[148,152,156,160,164,168,172,176,180,184,188,193,198,203,208,213,218,222,227,231,235,240,245,250,255,260,265,270,275,280,284],{"page_no":8,"url":149,"width":150,"height":151},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/d8169a59890c905210af2fc972d62ef7.webp",983,1285,{"page_no":14,"url":153,"width":154,"height":155},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/7aef6a44b81433f49957ffdfd995b804.webp",982,1305,{"page_no":81,"url":157,"width":158,"height":159},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/30b99434df145dd13928f6b115d96c6c.webp",981,1303,{"page_no":19,"url":161,"width":162,"height":163},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/0f4bc9e1982cb724987c250203341291.webp",980,1302,{"page_no":24,"url":165,"width":166,"height":167},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/f74b9ec1d9b837f5561da9e7416e3b98.webp",979,1301,{"page_no":29,"url":169,"width":170,"height":171},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/252485e5cfd44dd5fa2c8389a9cc8e56.webp",978,1299,{"page_no":34,"url":173,"width":174,"height":175},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/e65f05ea9d2104f1bac38da4c8bf4721.webp",977,1298,{"page_no":39,"url":177,"width":178,"height":179},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/bc3e3f80b63783aae6a6f5f25a518f5a.webp",976,1297,{"page_no":44,"url":181,"width":182,"height":183},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/4a83147277cf3d04ae607d77665602cd.webp",975,1295,{"page_no":52,"url":185,"width":186,"height":187},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/fd53f832dd04782b3e671dedd5cc95d6.webp",974,1294,{"page_no":189,"url":190,"width":191,"height":192},11,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/3912f0f00d96ec6bcba0393ff670e33c.webp",973,1293,{"page_no":194,"url":195,"width":196,"height":197},12,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/6e94851115d1d2d61873656314c1014b.webp",972,1291,{"page_no":199,"url":200,"width":201,"height":202},13,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/814905cc2c056daec7ecfd5fff537c0f.webp",971,1290,{"page_no":204,"url":205,"width":206,"height":207},14,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/ef8272c1ac3512bf63f244416d2c2e47.webp",970,1289,{"page_no":209,"url":210,"width":211,"height":212},15,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/77a86dd1ebea267b908c342723378096.webp",969,1287,{"page_no":214,"url":215,"width":216,"height":217},16,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/7d842ecf16b7507c9f2857fdcef8f733.webp",968,1286,{"page_no":219,"url":220,"width":221,"height":151},17,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/735332abfd1e3a45646e9b2fdca02ffb.webp",967,{"page_no":223,"url":224,"width":225,"height":226},18,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/1a9d5fb89eafd373faee8c43ebf773da.webp",966,1283,{"page_no":56,"url":228,"width":229,"height":230},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/905b5cd5b85d2f8c47d585941541c972.webp",965,1282,{"page_no":46,"url":232,"width":233,"height":234},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/4a09fbd61bc32099ed31451f5cc90e2d.webp",964,1281,{"page_no":236,"url":237,"width":238,"height":239},21,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/80c8ccdbee9b9702dfb540c83088150a.webp",963,1279,{"page_no":241,"url":242,"width":243,"height":244},22,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/bbd4c37ca7716bf269f8b0504c882b76.webp",962,1278,{"page_no":246,"url":247,"width":248,"height":249},23,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/8c047a9e1969dc70bede1f7bddbe7c41.webp",961,1277,{"page_no":251,"url":252,"width":253,"height":254},24,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/a5f1d733b70386f019e980e8ad1bc2c0.webp",960,1275,{"page_no":256,"url":257,"width":258,"height":259},25,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/63a93a4511be0da2f8fb04f9db5468e6.webp",959,1274,{"page_no":261,"url":262,"width":263,"height":264},26,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/b65ecc68c91054196d51623b2ee2a5a2.webp",958,1273,{"page_no":266,"url":267,"width":268,"height":269},27,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/075ddf7625b8f1150ef3c4d3a7c571a0.webp",957,1271,{"page_no":271,"url":272,"width":273,"height":274},28,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/6946bbdf9a1c5e6fc51e35dc3b0db407.webp",956,1270,{"page_no":276,"url":277,"width":278,"height":279},29,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/b58248129266e1cd3db5977d86cd4ecc.webp",955,1269,{"page_no":41,"url":281,"width":282,"height":283},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/14fbed60635d46d321da9cb7fdd1143c.webp",954,1267,{"page_no":146,"url":285,"width":286,"height":287},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/e6ce8e3b9475e5d74362470a5cab6a43.webp",953,1266,{"list":289,"token":66},[290,296,302,308,314,321,327,333,339,345],{"doc_id":291,"doc_title":292,"file_type":137,"home_preview_img_url":293,"slug":294,"view_count":261,"category_name":30,"create_tm":295},150822,"TechnoTurtle Python - Teacher Guide - Lessons for Elementary School Students","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229869770512/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=SdY5e%2Bj4HpB0WHQPrkSfgZ1uUuA%3D","technoturtle-python-teacher-guide-lessons-for-elementary-school-students",1787827634,{"doc_id":297,"doc_title":298,"file_type":137,"home_preview_img_url":299,"slug":300,"view_count":223,"category_name":30,"create_tm":301},116469,"Python Coding Simplified - Muriel Malopa Makosani","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229834233445/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=MfK%2BXr3De2wlWK0RbmkC9k3nG9k%3D","python-coding-simplified-muriel-malopa-makosani",1785659505,{"doc_id":303,"doc_title":304,"file_type":137,"home_preview_img_url":305,"slug":306,"view_count":81,"category_name":30,"create_tm":307},682645,"Python Basics: A Practical Introduction to Python 3 - Revised and Updated 4th Edition","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999674962/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=0HgOUHggf%2FHmO1%2BIhJvUL3EfGOE%3D","python-basics-a-practical-introduction-to-python-3-revised-and-updated-4th-edition",1793977304,{"doc_id":309,"doc_title":310,"file_type":137,"home_preview_img_url":311,"slug":312,"view_count":29,"category_name":30,"create_tm":313},682643,"Treading on Python Series Illustrated Guide to Python 3 - A Complete Walkthrough of Beginning Python with Unique Illustrations Showing how Python Really Works","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999674940/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=baVHbn2rkkoVFWxbjZ3WdabJPJE%3D","treading-on-python-series-illustrated-guide-to-python-3-a-complete-walkthrough-of-beginning-python-with-unique-illustrations-showing-how-python-really-works",1793977303,{"doc_id":315,"doc_title":316,"file_type":137,"home_preview_img_url":317,"slug":318,"view_count":319,"category_name":30,"create_tm":320},19157,"C++ & Python for Beginners","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229709434556/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=THXe4El2AI%2FSNvgFD5zDUSNr344%3D","c-python-for-beginners",65,1777154415,{"doc_id":322,"doc_title":323,"file_type":137,"home_preview_img_url":324,"slug":325,"view_count":19,"category_name":30,"create_tm":326},719777,"Python For Dummies - Introducing Python - Getting Started","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230023659675/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=hjBBzFkoL8PLOIfhBlRWx%2FGFhOM%3D","python-for-dummies-introducing-python-getting-started",1795031061,{"doc_id":328,"doc_title":329,"file_type":137,"home_preview_img_url":330,"slug":331,"view_count":29,"category_name":30,"create_tm":332},732848,"Basic HTML — Complete Notes","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230031412591/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=4EjshMcB573CO1XX1%2BO5uxxJZu0%3D","basic-html-complete-notes",1795382441,{"doc_id":334,"doc_title":335,"file_type":137,"home_preview_img_url":336,"slug":337,"view_count":24,"category_name":30,"create_tm":338},682648,"Python - Visual QuickStart Guide - Quick and easy way","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999674985/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=xxrwGh8w78nxcRyGg7KfXpDq8z0%3D","python-visual-quickstart-guide-quick-and-easy-way",1793977311,{"doc_id":340,"doc_title":341,"file_type":137,"home_preview_img_url":342,"slug":343,"view_count":189,"category_name":30,"create_tm":344},727275,"Python Programming - The Complete Guide to Learn Python for Data Science, AI, Machine Learning, GUI and More - With Practical Exercises and Interview Questions","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230028663614/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=4jeQXOU03BTc9Df4F0PtgIKt8Co%3D","python-programming-the-complete-guide-to-learn-python-for-data-science-ai-machine-learning-gui-and-more-with-practical-exercises-and-interview-questions",1795232765,{"doc_id":346,"doc_title":347,"file_type":137,"home_preview_img_url":348,"slug":349,"view_count":350,"category_name":30,"create_tm":351},143348,"Python Crash Course - 2nd edition - a hands-on, Project-Based introduction to Programming","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229867490008/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796115359&Signature=dw%2BqQQ2s%2BZy5mljvda6yWuznDWo%3D","python-crash-course-2nd-edition-a-hands-on-project-based-introduction-to-programming",44,1787694600]