Coder Social home page Coder Social logo

vovandreevik / cross-reference-generator Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 13 KB

This C++ program reads text from a file, generates a cross-reference table of words along with the lines they appear on, and prints the text with line numbers.

C++ 100.00%
cross-reference dictionary map vector cpp

cross-reference-generator's Introduction

Text Cross-Reference Generator

This C++ program reads text from a file, generates a cross-reference table of words along with the lines they appear on, and prints the text with line numbers.

It's a useful tool for quick word and line references in a text document.

Features

  • Text with Line Numbers: Displays the original text with line numbers, making it easier to reference specific lines.

  • Cross-Reference Table: Generates a cross-reference table of words and the lines they appear on.

  • Word Cleaning: Cleans words by removing non-alphabetic characters and converting them to lowercase for accurate word counts.

Input File Format

The input file should contain the text you want to process. The program reads and analyzes this text.

Example Input File:

cherry tree tree
Cherry;
mango cherry tree,
apple. %^**(@#
free 324235

Examples

Example command and expected output:

Text with Line Numbers:

1: cherry tree tree
2: Cherry;
3: mango cherry tree,
4: apple. %^**(@#
5: free 324235

Cross-Reference Table:

Words:          Lines:
apple           4
cherry          1 2 3
free            5
mango           3
tree            1 3

cross-reference-generator's People

Contributors

vovandreevik avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.