niieani / bash-oo-framework

Bash Infinity is a modern standard library / framework / boilerplate for Bash
https://github.com/niieani/bash-oo-framework/discussions
MIT License
5.57k stars 247 forks source link

Moved IT to examples #79

Closed kounkou closed 9 months ago

kounkou commented 5 years ago

Hi there !

I moved the IT example as discussed with @niieani To test :

$ git clone -b moved_it ...
$ cd example
$ bash intervaltree.sh

example result :

IntervalTree.InsertInterval
0 2 e0 provided

IntervalTree.InsertInterval
1 3 e1 provided

IntervalTree.InsertInterval
1 4 e2 provided

IntervalTree.InsertInterval
5 3 e3 provided

IntervalTree.InsertInterval
1 7 e4 provided

IntervalTree.SearchOverlaps
IntervalTree.Overlaps ( 1 2 ) <-?-> ( 0 2 ) true
IntervalTree.Overlaps ( 1 2 ) <-?-> ( 1 3 ) true
IntervalTree.Overlaps ( 1 2 ) <-?-> ( 1 4 ) true
IntervalTree.Overlaps ( 1 2 ) <-?-> ( 5 3 ) false
IntervalTree.Overlaps ( 1 2 ) <-?-> ( 1 7 ) true

IntervalTree.SearchOverlaps
IntervalTree.Overlaps ( 5 6 ) <-?-> ( 0 2 ) false
IntervalTree.Overlaps ( 5 6 ) <-?-> ( 1 3 ) false
IntervalTree.Overlaps ( 5 6 ) <-?-> ( 1 4 ) false
IntervalTree.Overlaps ( 5 6 ) <-?-> ( 5 3 ) false
IntervalTree.Overlaps ( 5 6 ) <-?-> ( 1 7 ) true

IntervalTree.PrintIntervals
0 2 e0
1 3 e1
1 4 e2
5 3 e3
1 7 e4

regards

kounkou commented 5 years ago

Hey @niieani This Pull Request fixes #59