/**
 * This function calculates the population density given the population and area of a location.
 * Population should be an integer representing the total population of the location.
 * Area should be an integer representing the total area of the location in square kilometers.
 *
 * @return An integer representing the population density of the location in people per square kilometer.
 */
fun calculatePopulationDensity(population: Int, area: Int): Int {

    // Applying conditional statements for error handling
    if (population <= 0 || area <= 0) {
        return 0 // Assuming 0 population density for invalid inputs
    }

    // Calculate population density
    val populationDensity = population / area
    return populationDensity
}
/**
 * This function calculates the population density given the population and area of a location.
 * Population should be an integer representing the total population of the location.
 * Area should be an integer representing the total area of the location in square kilometers.
 *
 * @return An integer representing the population density of the location in people per square kilometer.
 */
fun calculatePopulationDensity(population: Int, area: Int): Int {
/**
 * This function calculates the population density given the population and area of a location.
 * Population should be an integer representing the total population of the location.
 * Area should be an integer representing the total area of the location in square kilometers.
 *
 * @return An integer representing the population density of the location in people per square kilometer.
 */
fun calculatePopulationDensity(population: Int, area: Int): Int {

    // Applying conditional statements for error handling
    if (population <= 0 || area <= 0) {
        return 0 // Assuming 0 population density for invalid inputs
    }

    // Calculate population density
    val populationDensity = population / area
    return populationDensity
}