[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-697908-105":59,"doc-detail-697908-en":130,"doc-similar-697908":162},{"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","chapter-1-basic-principles-of-programming-languages-697908","Chapter 1 - Basic Principles of Programming Languages","","Chapter 1 explains common foundations that programming languages share despite their large variety. It introduces programming paradigms and how they shape computation, performance-related language features, and the historical development of programming languages. The chapter also previews language structure at lexical, syntactic, and semantic levels, covering data types, typing strength, and type checking during compilation. It further outlines preprocessing and processing, including macro handling, interpretation versus compilation, and execution models, then presents program development steps and correctness proof.",{"@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/chapter-1-basic-principles-of-programming-languages-697908/697908/",{"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/chapter-1-basic-principles-of-programming-languages-697908/697908.png","ImageObject",300,407,{"name":92,"@type":93},"Mafia Boss","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-11-28","2026-11-12",true,{"@type":102,"interactionType":103,"userInteractionCount":19},"InteractionCounter",{"@type":104},"ViewAction",{"@type":106,"mainEntity":107},"FAQPage",[108,114,118],{"name":109,"@type":110,"acceptedAnswer":111},"What are programming paradigms, according to the chapter?","Question",{"text":112,"@type":113},"Programming paradigms are a set of basic principles, concepts, and methods for expressing computation or algorithms. The major paradigms studied here are imperative, object-oriented, functional, and logic paradigms.","Answer",{"name":115,"@type":110,"acceptedAnswer":116},"How does the imperative (procedural) paradigm express computation?",{"text":117,"@type":113},"It expresses computation through fully specified, fully controlled manipulation of named data in a stepwise fashion. Values are stored in variables, read, processed in the ALU, and stored back, then sent to I/O devices as output.",{"name":119,"@type":110,"acceptedAnswer":120},"What distinguishes functional programming from imperative and object-oriented programming?",{"text":121,"@type":113},"Functional programming expresses computation as mathematical functions and does not use the concept of memory locations. Each function takes input parameters and produces a single return value that is used immediately or as an argument to another function.","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},697908,1794445795,{"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":19,"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":129,"read_time":144,"preview_page_count":19,"preview_urls":145},962090760730,"https://ap-avatar.wpscdn.com/davatar_9964176cb1d06d4a9deccf72a44ae3dc","Chapter 1  \nBasic Principles of Programming Languages  \nAlthough there exist many programming languages, the differences among them are insignificant compared to the differences among natural languages. In this chapter, we discuss the common aspects shared among different programming languages. These aspects include:  \n􀁸 programming paradigms that define how computation is expressed;  \n􀁸 the main features of programming languages and their impact on the performance of programs written in the languages;  \n􀁸 a brief review of the history and development of programming languages;  \n􀁸 the lexical, syntactic, and semantic structures of programming languages, data and data types, program processing and preprocessing, and the life cycles of program development.  \nAt the end of the chapter, you should have learned:  \n􀁸 what programming paradigms are;  \n􀁸 an overview of different programming languages and the background knowledge of these languages;  \n􀁸 the structures of programming languages and how programming languages are defined at the syntactic level;  \n􀁸 data types, strong versus weak checking;  \n􀁸 the relationship between language features and their performances;  \n􀁸 the processing and preprocessing of programming languages, compilation versus interpretation, and different execution models of macros, procedures, and inline procedures;  \n􀁸 the steps used for program development: requirement, specification, design, implementation, testing, and the correctness proof of programs.  \nThe chapter is organized as follows. Section 1.1 introduces the programming paradigms, performance, features, and the development of programming languages. Section 1.2 outlines the structures and design issues of programming languages. Section 1.3 discusses the typing systems, including types of variables, type equivalence, type conversion, and type checking during the compilation. Section 1.4 presents the  \npreprocessing and processing of programming languages, including macro processing, interpretation, and compilation. Finally, Section 1.5 discusses the program development steps, including specification, testing, and correctness proof.  \n1.1 Introduction  \n1.1.1 Programming concepts and paradigms  \nMillions of programming languages have been invented, and several thousands of them are actually in use. Compared to natural languages that developed and evolved independently, programming languages are far more similar to each other. This is because  \n􀁸 different programming languages share the same mathematical foundation (e.g., Boolean algebra, logic);  \n􀁸 they provide similar functionality (e.g., arithmetic, logic operations, and text processing);  \n􀁸 they are based on the same kind of hardware and instruction sets;  \n􀁸 they have common design goals: find languages that make it simple for humans to use and efficient for hardware to execute;  \n􀁸 designers of programming languages share their design experiences.  \nSome programming languages, however, are more similar to each other, while other programming languages are more different from each other. Based on their similarities or the paradigms, programming languages can be divided into different classes. In programming language’s definition, paradigm is a set of basic principles, concepts, and methods for how a computation or algorithm is expressed. The major paradigms we will study in this text are imperative, object-oriented, functional, and logic paradigms.  \nThe imperative, also called the procedural, programming paradigm expresses computation by fully specified and fully controlled manipulation of named data in a stepwise fashion. In other words, data or values are initially stored in variables (memory locations), taken out of (read from) memory, manipulated in ALU (arithmetic logic unit), and then stored back in the same or different variables (memory locations) . Finally, the values of variables are sent to the I/O devices as output. The foundation of imperative languages is the stored program con","cbCaij1T3u7RbkoP","https://ap.wps.com/l/cbCaij1T3u7RbkoP","pdf",1259546,39,"English","# 1.1 Introduction\n## 1.1.1 Programming concepts and paradigms\n# 1.1 Introduction\n## 1.1.1 Programming concepts and paradigms","[{\"question\":\"What are programming paradigms, according to the chapter?\",\"answer\":\"Programming paradigms are a set of basic principles, concepts, and methods for expressing computation or algorithms. The major paradigms studied here are imperative, object-oriented, functional, and logic paradigms.\"},{\"question\":\"How does the imperative (procedural) paradigm express computation?\",\"answer\":\"It expresses computation through fully specified, fully controlled manipulation of named data in a stepwise fashion. Values are stored in variables, read, processed in the ALU, and stored back, then sent to I/O devices as output.\"},{\"question\":\"What distinguishes functional programming from imperative and object-oriented programming?\",\"answer\":\"Functional programming expresses computation as mathematical functions and does not use the concept of memory locations. Each function takes input parameters and produces a single return value that is used immediately or as an argument to another function.\"}]","Chapter 1 - Basic Principles of Programming Languages | PDF",98,[146,150,154,158],{"page_no":8,"url":147,"width":148,"height":149},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-12/21b81e99e07f97665e2140a478315195.webp",983,1272,{"page_no":14,"url":151,"width":152,"height":153},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-12/415ee369d4878f51f741f9ace4f8460f.webp",982,1270,{"page_no":81,"url":155,"width":156,"height":157},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-12/b250c24cb8e26d02fff78ded0c641232.webp",981,1269,{"page_no":19,"url":159,"width":160,"height":161},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-12/39709f2d56243f2d484a22d26ea25189.webp",980,1268,{"list":163,"token":66},[164,170,176,182,189,196,203,209,216,222],{"doc_id":165,"doc_title":166,"file_type":137,"home_preview_img_url":167,"slug":168,"view_count":19,"category_name":30,"create_tm":169},697911,"Organization of Programming Languages - read online free","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230009210114/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=HGE02p0ZpR77hSSJWVpPdx4p%2FY8%3D","organization-of-programming-languages-read-online-free",1794445801,{"doc_id":171,"doc_title":172,"file_type":137,"home_preview_img_url":173,"slug":174,"view_count":81,"category_name":30,"create_tm":175},697913,"Introduction to Programming Languages - Objectives","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230010130478/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=Hl7JnI72xUiw8UXMIe%2BuW0FDQ10%3D","introduction-to-programming-languages-objectives",1794445808,{"doc_id":177,"doc_title":178,"file_type":137,"home_preview_img_url":179,"slug":180,"view_count":81,"category_name":30,"create_tm":181},697909,"Programming Languages - Principles and Practice - Third Edition","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230010130355/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=3mOXxxrx7K9R4jI%2Fs%2BAw8JyG%2FMo%3D","programming-languages-principles-and-practice-third-edition",1794445799,{"doc_id":183,"doc_title":184,"file_type":137,"home_preview_img_url":185,"slug":186,"view_count":187,"category_name":30,"create_tm":188},40219,"Chapter08 JavaScript1 Language Fundamentals","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229795152321/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=HWn0t2dUe5pxCkGZsemLtK2uhKk%3D","chapter08-javascript1-language-fundamentals",26,1783306973,{"doc_id":190,"doc_title":191,"file_type":137,"home_preview_img_url":192,"slug":193,"view_count":194,"category_name":30,"create_tm":195},45838,"Implementing Programming Languages An Introduction to Compilers and Interpreters","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229797748707/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=DVLqoKbWqDwQNar2N5g0FXARPOI%3D","implementing-programming-languages-an-introduction-to-compilers-and-interpreters",28,1783467164,{"doc_id":197,"doc_title":198,"file_type":137,"home_preview_img_url":199,"slug":200,"view_count":201,"category_name":30,"create_tm":202},347395,"Programming In C - Part 1 - Introduction","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229911021193/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=V6I8YID0SdFDcRdqFzf%2Bwz%2BzMWE%3D","programming-in-c-part-1-introduction",31,1790066769,{"doc_id":204,"doc_title":205,"file_type":137,"home_preview_img_url":206,"slug":207,"view_count":19,"category_name":30,"create_tm":208},685640,"Programming Language Principles and Paradigms - Release 0.4 - Notes","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999084377/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=flj9Uk3owspyUtQMImG%2F4Lb1S5U%3D","programming-language-principles-and-paradigms-release-04-notes",1794016120,{"doc_id":210,"doc_title":211,"file_type":137,"home_preview_img_url":212,"slug":213,"view_count":214,"category_name":30,"create_tm":215},267237,"Competitive Programming - Algorithm and Data Structures Guide","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229898561470/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=kUPplj7hkQeflEXZuDDaNtlvNS8%3D","competitive-programming-algorithm-and-data-structures-guide",13,1789416248,{"doc_id":217,"doc_title":218,"file_type":137,"home_preview_img_url":219,"slug":220,"view_count":19,"category_name":30,"create_tm":221},685636,"The A-Z of Programming Languages - interviews with programming language creators - Ada","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999084240/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=QJ1%2Fg%2BWz8cyT%2BDF5TEoJyqS%2BVl0%3D","the-a-z-of-programming-languages-interviews-with-programming-language-creators-ada",1794016110,{"doc_id":223,"doc_title":224,"file_type":137,"home_preview_img_url":225,"slug":226,"view_count":227,"category_name":30,"create_tm":228},424686,"Programming - Chapter 3 - Natural Languages and Programming Languages","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229922357828/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796116199&Signature=5leuCtAhPYXZY59LqLCP%2Bi1MN2A%3D","programming-chapter-3-natural-languages-and-programming-languages",15,1790635065]