Skip to content

Commit

Permalink
Auto-generated commit
Browse files Browse the repository at this point in the history
  • Loading branch information
stdlib-bot committed Jan 16, 2024
1 parent 350c882 commit ca45ee6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
9 changes: 4 additions & 5 deletions base/to-reversed/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,18 +85,17 @@ var bool = ( out === x );
<!-- eslint no-undef: "error" -->
```javascript
var Float64Array = require( '@stdlib/array/float64' );
var zeroTo = require( '@stdlib/array/base/zero-to' );
var toReversed = require( '@stdlib/array/base/to-reversed' );
var x = new Float64Array( zeroTo( 6 ) );
// returns <Float64Array>[ 0.0, 1.0, 2.0, 3.0, 4.0, 5.0 ]
var x = zeroTo( 6 );
// returns [ 0, 1, 2, 3, 4, 5 ]
var y = toReversed( x );
// returns <Float64Array>[ 5.0, 4.0, 3.0, 2.0, 1.0, 0.0 ]
// returns [ 5, 4, 3, 2, 1, 0 ]
var z = toReversed( y );
// returns <Float64Array>[ 0.0, 1.0, 2.0, 3.0, 4.0, 5.0 ]
// returns [ 0, 1, 2, 3, 4, 5 ]
```

</section>
Expand Down
9 changes: 4 additions & 5 deletions base/to-reversed/examples/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,17 @@

'use strict';

var Float64Array = require( './../../../float64' );
var zeroTo = require( './../../../base/zero-to' );
var toReversed = require( './../lib' );

var x = new Float64Array( zeroTo( 6 ) );
var x = zeroTo( 6 );
console.log( x );
// => <Float64Array>[ 0.0, 1.0, 2.0, 3.0, 4.0, 5.0 ]
// => [ 0, 1, 2, 3, 4, 5 ]

var y = toReversed( x );
console.log( y );
// => <Float64Array>[ 5.0, 4.0, 3.0, 2.0, 1.0, 0.0 ]
// => [ 5, 4, 3, 2, 1, 0 ]

var z = toReversed( y );
console.log( z );
// => <Float64Array>[ 0.0, 1.0, 2.0, 3.0, 4.0, 5.0 ]
// => [ 0, 1, 2, 3, 4, 5 ]

0 comments on commit ca45ee6

Please sign in to comment.