This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
// OpenZeppelin Contracts v4.4.0 (access/Ownable.sol) | |
pragma solidity ^0.8.0; | |
import "../utils/Context.sol"; | |
/** | |
* @dev Contract module which provides a basic access control mechanism, where | |
* there is an account (an owner) that can be granted exclusive access to |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.0; | |
import "../utils/Context.sol"; | |
/** | |
* @dev Contract module which provides a basic access control mechanism, where | |
* there is an account (an owner) that can be granted exclusive access to | |
* specific functions. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# path to the image | |
# needs to be 72 DPI to be read properly | |
path = u"/Volumes/Macintosh HD/Users/jonathon/mcdonalds8.jpeg" | |
import random | |
# get the size of the image | |
w, h = imageSize(path) | |
size(w, h) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
size(500,500) | |
import random | |
for x in range( 0, 500, 10 ): | |
for y in range( 0, 500, 10 ): | |
radius = random.randint( 1, 4 ) | |
strokeWidth(0) | |
oval( x, y, radius, radius) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
size(500,500) | |
import random | |
for x in range( 0, 500, 10 ): | |
for y in range( 0, 500, 10 ): | |
radius = random.randint( 1, 4 ) | |
oval( x, y, radius, radius) |