/**
 * This function calculates the number of vignettes that can be placed on a photo based on the photo's dimensions and the dimensions of the frame.
 *
 * @param photoWidth the width of the photo in millimeters
 * @param photoHeight the height of the photo in millimeters
 * @param frameWidth the width of the frame in millimeters
 * @param frameHeight the height of the frame in millimeters
 * @return the maximum number of vignettes that can fit on the photo
 */
fun calculateVignettes(photoWidth: Int, photoHeight: Int, frameWidth: Int, frameHeight: Int): Int {

    // Calculate the maximum possible number of vignettes for each dimension
    val maxVignettesWidth = (photoWidth - frameWidth) / frameWidth + 1
    val maxVignettesHeight = (photoHeight - frameHeight) / frameHeight + 1

    // Calculate the total number of vignettes by taking the intersection of the possible ranges for both dimensions
    val numVignettes = (0 until maxVignettesWidth).intersect(0 until maxVignettesHeight).count()

    return numVignettes
}
/**
 * This function calculates the number of vignettes that can be placed on a photo based on the photo's dimensions and the dimensions of the frame.
 *
 * @param photoWidth the width of the photo in millimeters
 * @param photoHeight the height of the photo in millimeters
 * @param frameWidth the width of the frame in millimeters
 * @param frameHeight the height of the frame in millimeters
 * @return the maximum number of vignettes that can fit on the photo
 */
fun calculateVignettes(photoWidth: Int, photoHeight: Int, frameWidth: Int, frameHeight: Int): Int {
/**
 * This function calculates the number of vignettes that can be placed on a photo based on the photo's dimensions and the dimensions of the frame.
 *
 * @param photoWidth the width of the photo in millimeters
 * @param photoHeight the height of the photo in millimeters
 * @param frameWidth the width of the frame in millimeters
 * @param frameHeight the height of the frame in millimeters
 * @return the maximum number of vignettes that can fit on the photo
 */
fun calculateVignettes(photoWidth: Int, photoHeight: Int, frameWidth: Int, frameHeight: Int): Int {

    // Calculate the maximum possible number of vignettes for each dimension
    val maxVignettesWidth = (photoWidth - frameWidth) / frameWidth + 1
    val maxVignettesHeight = (photoHeight - frameHeight) / frameHeight + 1

    // Calculate the total number of vignettes by taking the intersection of the possible ranges for both dimensions
    val numVignettes = (0 until maxVignettesWidth).intersect(0 until maxVignettesHeight).count()

    return numVignettes
}