OpenLLM-France/wikimedia huggingface dataset:
# Civic Technology/Give Directions

Having your community accurately represented on digital maps and geographic guides is very important. By ensuring your community is well marked, one can help reduce the number of people who are lost in your community, as well as make it easier for people to conduct business.

## OpenStreetMap

* The OpenStreetMap website in 2020.
OpenStreetMap (OSM for short) is a freely available, open source map of the world which anyone can edit, just like Wikibooks or Wikipedia. Behind the scenes, many programs use OpenStreetMap to provide directions and other information to their users. Here are just a few ways OpenStreetMap data is often silently used by common applications.
* Giving Directions to travelers, delivery drivers, and general motorists.
* Assisting visually impaired people by applications that use OSM to note sidewalk info.
The OpenStreetMap community maintains their own beginners' guide.

## Wikivoyage

While basic maps are well and good, they don't offer further context of a location to a visitor. That's where Wikibooks and Wikipedia sister project Wikivoyage comes into play.
Wikivoyage is a travel guide that assists tourists in their journeys. Even if your city isn't a tourist hotspot, it may well lie on someone's journey, so it's worthwhile to improve local articles there. This helps tourists find local businesses, events, and other amenities to spend their time and money while visiting. Assisting tourists to have the best experience your community offers is mutually beneficial for both the community and the traveler.
If you want to act as a guide, you can become a docent on Wikivoyage as well.
Wikivoyage maintains a beginners guide with their plunge forward page. Editing Wikivoyage articles is easy, and many articles can be easily improved with a graphical listing editor.
# Communication Networks/Duplex Networks

Duplex Networks, or networks where data travels in both directions between two nodes, pose the problem of needing two channels to communication between two nodes, instead of just one for a broadcast networks.
# Communication Networks/Glossary
## Access Point

    A layer 1 device that interconnects a wireless network with a wired network.

## Bridge

    A layer 2 device that interconnects two or more existing networks.

## Firewall

    A multi-layer device that makes decisions on what data to forward on to its destination, and what data to block from its destination.

## Hub

    A layer 1 device that physically connects two or more network devices together. Similar to a switch, but less efficient. Every device receives and sends to and from every other device connected to the hub.

## Network

    A collection of two or more devices which are interconnected using common protocols to exchange data.

## Node

    Any device connected to a network.

## Protocol

    Any agreed upon standard used for communication.

## Request for Comments (RFC)

    A specification of an internet standard or protocol.

## Router

    A layer 3 device that decides how to forward a packet based on its desired destination.

## Switch

    A layer 2 device that logically connects two or more devices in a network for more isolated communication. Some devices sold as switches are also capab
# Communication Networks/History of Networking
## Timeline

The cellular concept of space-divided networks was first developed in AT&T in the 1940's and 1950's. AMPS, an analog frequency division multiplexing network was first implemented in Chicago in 1983, and was completely saturated with users the next year. The FCC, in response to overwhelming user demand, increased the available cellular bandwidth from 40Mhz to 50Mhz.
The second generation (see below) started in the early 1990's with the advent of the Digital European Cordless Telephone (DECT) system, and the Global System for Mobile Communication (GSM). Data networks were also developed such as HiperLAN and the IEEE 802.11 working group, which produced the 802.11 legacy standard in 1997. The 802.11a and 802.11b revisions were standardized in October 1999.
The third generation started with the CDMA2000 standard in Korea, and UMTS in Europe and FOMA in Japan. The IEEE 802.16 WiMAX specification was approved in December 2001.

## Wireless Generations

It is often instructive to break the history of wireless networking up into several specific generations.

### First Generation (1G)

The 1G wireless generation comprised of mainly analog signals for carrying voice and music. These were one directional broadcast systems such as Television broadcast, AM/FM radio, and similar communications.

### Second Generation (2G)

2G introduced concepts such as TDMA and CDMA for allowing bi-directional communications among nodes in large networks. 2G is when some of the first cellular phones were made available, although communications were restricted to very low bit-rates.
The second generation is frequently divided into sub-sets as well. "2.5G" represented a significant increase in throughput capacity as digital communications techniques became more refined. "2.75G" is another common pseudo-generation that saw an additional increase in speed and capacity among digital wireless networks.

### Third Generation (3G)

3G represents the combination of voice traffic with data traffic, and the advent of high-bandwidth mobile devices such as PDAs and smartphones. Spectrum Band Freq. varies depending on the mobile technology standard adopted in the system. Current HSDPA deployments support down-link speeds of 1.8, 3.6, 7.2 and 14.0 megabit/s and the HSPA family with up-link speeds up to 5.76 Mbit/s.

### Fourth Generation (4G)

4G is the current generation wireless network and is characterized by the ubiquity of broadband data connections and universal Internet access. Many of these networks are being designed around the WiMAX (IEEE 802.16) specification. 4G has created a paradigm shift in viewing voice as data, with technologies like Voice over LTE (VoLTE) trying to replace the traditional 1G and 2G voice networks. 4G LTE offered higher bandwidth than home Wi-Fi networks reaching speeds up to 20 Mbps. LTE Advanced also known as 3GPP has a peak upload speed of 500 Mbps and download speed of 1000 Mbps.

### Fifth Generation (5G)

The next generation of wireless networks, currently under development.
# Database Design/About the Book
## A Note to Readers

The primary purpose of this text is to provide an open source textbook that covers most introductory database courses. The material in the textbook was obtained from a variety of sources. All the sources are found in at the end of each chapter. I expect, with time, the book will grow with more information and more examples.
I welcome any feedback that would improve the book. If you would like to add a section to the book, please let me know.
Adrienne Watt

## About the Book

Database Design – 2nd Edition is a remix and adaptation, based on Adrienne Watt’s book, Database Design. Works that are part of the remix for this book are listed at the end of each chapter. For information about what was changed in this adaptation, refer to the Copyright statement at the bottom of the home page.
This adaptation is a part of the B.C. Open Textbook project.
In October 2012, the B.C. Ministry of Advanced Education announced its support for the creation of open textbooks for the 40 highest-enrolled first and second year subject areas in the province’s public post-secondary system.
Open textbooks are open educational resources (OER); they are instructional resources created and shared in ways so that more people have access to them. This is a different model than traditionally copyrighted materials. OER are defined as âteaching, learning, and research resources that reside in the public domain or have been released under an intellectual property license that permits their free use and re-purposing by others (Hewlett Foundation).
Our open textbooks are openly licensed using a Creative Commons license, and are offered in various e-book formats free of charge, or as printed books that are available at cost.
For more information about this project, please contact opentext@bccampus.ca .
If you are an instructor who is using this book for a course, please let us know.

## References

* BCOpenCampus: Database Design
# Database Design/Acknowledgements
## Adrienne Watt

This book has been a wonderful experience in the world of open textbooks. It’s amazing to see how much information is available to be shared. I would like to thank Nguyen Kim Anh of OpenStax College, for her contribution of database models and the relational design sections. I would also like to thank Dr. Gordon Russell for the section on normalization. His database resources were wonderful. Open Learning University in the UK provided me with a great ERD example. In addition, Tom Jewet provided some invaluable UML contributions.
I would also like to thank my many students over the years and a special instructor, Mitra Ramkay (BCIT). He is fondly remembered for the mentoring he provided when I first started teaching relational databases 25 years ago. Another person instrumental in getting me started in creating an open textbook is Terrie MacAloney. She was encouraging and taught me think outside the box.
A special thanks goes to my family for the constant love and support I received throughout this project.

## Nelson Eng

I would like to thank the many people who helped in this edition including my students at Douglas College and my colleague Ms. Adrienne Watt.
We would like to particularly thank Lauri Aesoph at BCcampus for her perseverance and hard work while editing the book. She did an amazing job.

## References

* BCOpenCampus: Database Design
# Data Structures/Trees/Hashing Memory Checking Example

Java implementation of a basic persistent database index using the linear hash algorithm
# Database Design

Database design is the organisation of data according to a database model. The designer determines what data must be stored and how the data elements interrelate. With this information, they can begin to fit the data to the database model. Database design involves classifying data and identifying interrelationships. This theoretical representation of the data is called an ontology. The ontology is the theory behind the database's design.

## Table of Contents

* Preface
** About the Book
** About the Authors
** Acknowledgements
* Before the Advent of Database Systems
* Fundamental Concepts
* Characteristics and Benefits of a Database
* Types of Data Models
* Data Modeling
* Classification of Database Management Systems
* The Relational Data Model
* The Entity Relationship Data Model
* Integrity Rules and Constraints
* ER Modeling
* Functional Dependencies
* Normalization
* Database Development Process
* Database Users
* SQL Structured Query Language
* SQL Data Manipulation Language
* Appendix
** University Registration Data Model Example
** Sample ERD Exercises
** SQL Lab with Solution
** Orders and Data

## References

* ↑ Wikipedia: Database design
# Database Design/About the Authors
## Primary Author: Adrienne Watt

Adrienne Watt holds a computer systems diploma (BCIT), a bachelor’s degree in technology (BCIT) and a master’s degree in business administration (City University).
Since 1989, Adrienne has worked as an educator and gained extensive experience developing and delivering business and technology curriculum to post-secondary students. During that time, she ran a successful software development business. In the business, she worked as an IT professional in a variety of senior positions including project manager, database designer, administrator and business analyst. Recently she has been exploring a wide range of technology-related tools and processes to improve delivery methods and enhance learning for her students.

## Contributing Author: Nelson Eng

Nelson Eng completed his bachelor’s degree in commerce (accounting and management information systems) from the University of British Columbia and a master’s degree in computer science from the University of Western Ontario. He spent 11 years as a computer systems coordinator with Science World of B.C. and 14 years as a computer science and information systems instructor with Douglas College.

## References

* BCOpenCampus: Database Design
# C Programming/string.h/strrchr

strrchr is function in string.h. It is mainly used to locate last occurrence of character in string, searching from the end. It returns a pointer to the last occurrence of character in the C string str. The terminating null-character is considered part of the C string. Therefore, it can also be located to retrieve a pointer to the end of a string.

## Syntax

In C, this function is declared as:
char *strrchr ( const char *, int );
str is a C string. character is the character to be located. It is passed as its int promotion, but it is internally converted back to char.

## Return value

A pointer to the last occurrence of character in str. If the value is not found, the function returns a null pointer.

## Example

Output : Last occurrence of 's' found at 18.

## See also

strchr

## References

* ↑ ISO/IEC 9899:1999 specification (PDF). p. 343, § 7.12.4.3.

## External links

* some information about strchrnul
* C++ reference for std::strrchr
# C Programming/string.h/strtok

strtok
strtok is one of the C-library function. The syntax of strtok function is as follow: Syntax:
Description: The strtok function returns a pointer to the next "token" in str1, where str2 contains the delimiters that determine the token. strtok returns NULL if no token is found. In order to convert a string to tokens, the first call to strtok should have str1 point to the string to be tokenized. All calls after this should have str1 be NULL.
# C Programming/string.h/stricmp

Prototype of stricmp function is
stricmp(str1,str2) compares str1 and str2 lexicographically without regards to case . It returns a negative value if str1<str2; 0 if str1 and str2 are identical; and positive value if str1>str2.
Example:

## References

* "stricmp", C Programming Expert.com
# C Programming/string.h/strncmp

strncmp is a standard-library function that compares two strings up to a specified length. The function is declared in string.h, and is compatible with the following prototype:
The function compares the strings using a lexicographical ordering, but never examines more than num characters. It returns zero if the strings are equal, or if their first num characters are equal; otherwise, it returns a negative integer if s1 is less than s2, and a positive integer if s1 is greater than s2. A simple implementation might be as follows:
In practice, however, real implementations are significantly optimized.

## See also

* strcmp

## External links

* C++ reference for std::strncmp
# C Programming/string.h/strlen

In the C standard library, strlen is a string function that determines the length of a C character string.

## Example usage

This program will print the value 11, which is the length of the string "Hello World". Character strings are stored in an array of a data type called char. The end of a string is found by searching for the first null character in the array.
Note importantly that this length does *NOT* include the array entry for the trailing null byte required for the ending character of C strings. Thus, if you need to copy the C string, you need to allocate a space of strlen + 1.

## Implementation

FreeBSD 6.2 implements strlen like so:
It is possible to write faster versions in C that examines full machine word rather than byte-by-byte. Hacker's Delight has given an algorithm that makes use of bitwise operations to detect if any of these bytes is nul ('\0'). The current FreeBSD implementation does this.
Modern C compilers usually provide fast inline versions of strlen written in assembly, either using the bitwise operation technique or a special instruction provided by certain CISC processors. In addition, strlen of a quoted string constant is often optimized into a constant integer.

## References

* ↑ "strlen.c Revision 1.4". FreeBSD. 2002-03-21. Retrieved 2009-03-04.
* ↑ "Contents of /stable/10/lib/libc/string/strlen.c". FreeBSD. 2013-10-10.

## External links

* strlen(3): calculate the length of a string – Linux Library Functions Manual
* C++ reference for std::strlen
# C Programming/string.h/strstr

strstr is a C standard library string function as defined in string.h. strstr has the function signature char * strstr(const char *haystack, const char *needle); which returns a pointer to a character at the first index where needle is in haystack, or NULL if not present.
The strcasestr is a function much like strstr except that it ignores the case of both needle and haystack. strcasestr is a non-standard function while strstr conforms to C89 and C99.

## Example

cptr is now a pointer to the sixth letter (e) in "wikipedia".

## See also

* strchr

## References

* 1 2 strcasestr(3)

## External links

* C++ reference for std::strstr
# C Programming/string.h/strxfrm

strxfrm is a C Standard Library string function declared in string.h. It transforms string according to the current locale setting.
The prototype of this function is:

## Parameters
#### str1

is the string which receives num characters of transformed string. If num is equal to zero then str1 contains only null character.

#### str2

is the string which is to be transformed.

#### num

is the maximum number of characters which to be copied into str1.

## Description

strxfrm function transforms str2 according to the current locale setting.For that LC_COLLATE category is used which is defined in locale.h. After transformation, the first num characters of the transformed string is copied into str1. strxfrm function performs transformation in such a way that result of strcmp on two strings is the same as result of strcoll on two original strings.

## Return Value

strxfrm function returns length of transformed string excluding terminating null character.

## Example usage
### Output

The length of str2 = 11 The content of str1 = Hell The content of str2 = Hello World

## External links

* strxfrm(3) – Linux Library Functions Manual
* C++ reference for std::strxfrm
# C Programming/string.h/strcspn

strcspn is the function from the C standard library (header file string.h).
It searches the string for certain set of characters.
The strcspn function calculates the length of initial segment of string 1 which does not contain any character from string 2.

## Return Value

This function returns the index of first character in string 1 that matches with any character of string2.

## Example

Output:
The first decimal digit of s is at position: 10

## References

* opengroup.org

## External links

* strcspn at cplusplus.com
* strcspn at en.cppreference.com
* opengroup.org
* msdn.microsoft.com
# C Programming/string.h/strerror

The string-error function, strerror, is a C/C++ function which translates an error code, usually stored in the global variable errno, to a human-readable error message.

## History

The strerror function is defined in IEEE Std 1003.1, also known as POSIX 1.

## Reentrancy

The strerror function is not reentrant. For a reentrant version of the function, see strerror r.

## Usage
### Semantics

The function generates and reports a C-style string, containing an error message derived from the error code passed in with errnum.

## See also

* strerror r
* perror

## References

* strerror by OpenGroup

## External links

* C++ reference for std::strerror
# C Programming/string.h/strspn

strspn function is used to find out the length of substring or length of maximum initial segment of the string pointed to by one string, let's say s1 containing all characters from another string pointed to by another string say s2.While strscpn is used to find out length of initial segment containing all elements not in the reject list.

## Syntax

size_t strspn(const char *s, const char *accept);
size_t strcspn(const char *s, const char *reject);

## Parameters

s1- It points to null-terminated string to be searched.
s2- It points to null-terminated set of characters.

## Reference

ANSI/ISO 9899-1990. Linux programmer's manual.

## See also

index(3), memchr(3), rindex(3), strchr(3), string(3), strpbrk(3), strsep(3),strstr(3), strtok(3), wcscspn(3), wcsspn(3)
# Descriptive Geometry/Distances/True Length

Finding the true length is a fundamental process in descriptive geometry that advances the problem-solving to the next steps to reach the solution. To find the true length of a line you must take a view parallel to the line; in other words, if a line is a parallel to the folding line in one view, it is shown in true length in the adjacent view. If a line is parallel to the folding line in both adjacent views, as for example in both the top and front views, then it is shown in true length in both of those views, and in such cases no additional work must be done if the only goal is to find the true length of the line.
# Descriptive Geometry/Edge View

Edge view is a view looking at one side of a plane. Planes in edge view are shown as lines that are the distances of the edges of the shape. To get edge view, take a view parallel to a side of a plane. Then take another view perpendicular to the new line. Alternatively, if you already have front and top views of the plane, to get an edge view you may draw - in either view - a line from one side of the plane to the other that is parallel to the folding line, transfer this line to the other view, and then take a view perpendicular to the line from that second view. Use transfer distances from the first view to get the endpoints of the plane and complete the edge view of a plane.
# Descriptive Geometry/Axonometric Projection/Practice Problems/Problem 2

Solution Problem 2