Contents
Guide
Laxmisha Rai
Programming in C++
Information and Computer Engineering
Volume 5
Already published in the series
Volume 4
Shuqin Lou, Chunling Yan, Digital Electronic Circuits, 2018
ISBN 978-3-11-061466-4, e-ISBN 978-3-11-061491-6, e-ISBN (EPUB) 978-3-11-061493-0
Volume 3
Baolong Guo, Signals and Systems, 2018
ISBN 978-3-11-059541-3, e-ISBN 978-3-11-059390-7, e-ISBN (EPUB) 978-3-11-059296-2
Volume 2
Jie Yang, Congfeng Liu, Random Signal Analysis, 2018
ISBN 978-3-11-059536-9, e-ISBN 978-3-11-059380-8, e-ISBN (EPUB) 978-3-11-059297-9
Volume 1
Beija Ning, Analog Electronic Circuit, 2018
ISBN 978-3-11-059540-6, e-ISBN 978-3-11-059386-0, e-ISBN (EPUB) 978-3-11-059319-8
Author
Laxmisha Rai
College of Electronic and Information Engineering
Shandong University of Science and Technology,
Qingdao, China.
ISBN 978-3-11-059539-0
e-ISBN (PDF) 978-3-11-059384-6
e-ISBN (EPUB) 978-3-11-059295-5
ISSN 2570-1614
Library of Congress Control Number: 2018954463
Bibliographic information published by the Deutsche Nationalbibliothek
The Deutsche Nationalbibliothek lists this publication in the Deutsche Nationalbibliografie; detailed bibliographic data are available on the Internet at http://dnb.dnb.de.
2019 Walter de Gruyter GmbH, Berlin/Boston, Science Press
Cover image: Prill/iStock/Getty Images Plus
www.degruyter.com
Preface
Today, use of computers and application of software can be seen everywhere. The rapid progress in information technology (IT) has changed our conventional ways of thinking. It is hard to imagine life without computers and software these days. Programming is an essential part of computing. Many programming languages were developed over the years, however, very few of them survived in the IT market. C++ is one such programming language that can rightly be called as a successor to C language. C++ is a general-purpose programming language with a rich set of object-oriented programming (OOP) and generic programming features. This language was created by Bjarne Stroustrup, a Danish computer scientist, in 1980s. Today, C++ is one of the most prominent and useful OOP languages. It is studied widely by students and programmers alike. C++ supports a number of features, such as classes, objects, inheritance, constructors, and polymorphism that make it so useful. This book covers all of these concepts along with the basics of programming, including selection statements, looping, arrays, strings, function sorting, and searching algorithms.
The book is written by focusing programmers, both experienced and inexperienced, who would like to learn C++ with or without any prior programming experience. The main objective of the book is to present an overview of C++ programming language with OOP concepts. The book is presented in simple English and easy examples. It can be used as a textbook for graduate or undergraduate programs. The book will provide every reader an idea to write and practice C++ programs as well as understanding various computers and programming terms in English. There are many features that will make this book unique among C++ textbooks. A large number of example programs and illustrations will be presented throughout the book. All of the programs are written with maximum care and attention. Many programming exercises are also provided, wherever necessary. We are sure that every reader will enjoy C++ programming while reading this book.
This book covers almost all of the necessary features of object-oriented programming with C++. There are a total of 18 chapters in the book. Each chapter starts with a brief introduction about its contents and scope. Each chapter has a set of questions for the reader to answer and think about possible answers as well. The book presents over 180 complete programs with their respective input and output details. We suggest every reader to go through all of the chapters starting from 1 to 18 in order to master C++ programming. This book can be divided into two parts. The first part is from to understand the OOP concepts directly. However, the book is written in such a way that the reader can jump to any chapter to acquire exact information without following the sequence of chapters.
In addition to all these chapters, the book presents five appendices for supporting the materials presented in this book. Appendix A provides the list of C++ header files and library functions. It is provided as a quick reference for learners to locate several library functions provided by C++. The brief description of these header files and respective library functions are provided in multiple tables. Appendices B and C provide a list of non-OOP and OOP exercises of C++, respectively. The book provides two different sections, so that the instructors are able to divide the exercises on the basis of the students ability and course requirements. In some universities or colleges, instructors prefer their students to learn object-oriented concepts of C++ only. In such cases, it is better to refer to the exercises shown in Appendix C. However, if the instructor is more focused on teaching fundamentals of programming concepts through C++, then programming exercises listed in Appendix B are preferable. In addition to these programming exercises, there are also some programming exercises presented at the end of each chapter in section Review Questions.
Appendix D lists the Decimal-Binary-Octal-Hex ASCII (American Standard Code for Information Interchange) conversion chart. It is very useful while writing programs of especially related character data type. In addition, it is necessary for learners to understand how the numbers are represented in different formats. Appendix E provides Bibliography information.
The book uses different fonts such as bold , and Inconsolata, to identify the various concepts. For example, the bold text reminds the user that these words are important and commonly used terms in understanding concepts of C++ and OOP. All the programs shown in the book are in Inconsolata, so that the readers can easily identify them. Moreover, we have also used this font within the text for describing the concepts, to show the readers that these words may form a part of a program, or beclosely related to a program. The outputs of example programs are also provided so that the readers can easily guess that the results obtained after the execution of program.
We hope that you find this book interesting, enjoyable, and informative. We wish all the readers every success in C++ programming.
Happy Programming!
Laxmisha Rai
About the Author
Laxmisha Rai received a bachelors degree in computer engineering at Mangalore University and a masters degree in computer science and engineering at Manipal Institute of Technology of India. He received a PhD in electronics from Kyungpook National University, South Korea. He was also a postdoctoral researcher at Soongsil University, South Korea.
Since 2010, he has been working as a professor at Shandong University of Science and Technology, China. Dr. Rai has lectured at several conferences in the United States, the United Kingdom, and several countries of Asia. His research interests are software engineering, knowledge-based systems, real-time systems, embedded systems, mobile robots, wireless sensor networks, and massive open online courses. He is the author of two books including Programming in Java with Object-Oriented Features , two patents, and over 50 research papers in international journals and conferences. He is a senior member of IEEE. He is also a member of ACM.