This file contains hidden or 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
const test = [ | |
{ name: "0", email: "[email protected]" }, | |
{ name: "1", email: "[email protected]" }, | |
{ name: "2", email: "[email protected]" }, | |
{ name: "3", email: "[email protected]" }, | |
{ name: "4", email: "[email protected]" }, | |
{ name: "5", email: "[email protected]" }, | |
{ name: "6", email: "[email protected]" }, | |
{ name: "7", email: "[email protected]" }, | |
{ name: "8", email: "[email protected]" }, |
This file contains hidden or 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
// Don't bother with import classes, this is not the problem here, you can add one if you have to. | |
// The goal is to refactor the functions (getWeather / getLocation) and inside the render() function. | |
// You can change state var or add one. things must be write once if it's possible and your code must be clear | |
// and understandable. | |
import React from "react"; | |
import Form from "./Form"; | |
import WeatherDiv from "./WeatherDiv"; | |
import "./Form.css" | |
import "./WeatherAPi.css" | |
import Slider from "react-slick" |
This file contains hidden or 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
import React from "react"; | |
import Form from "./Form"; | |
import WeatherDiv from "./WeatherDiv"; | |
import "./Form.css" | |
import "./WeatherAPi.css" | |
import Slider from "react-slick" | |
import ActivityCards from "./ActivityCards" | |
import Activity from "./Activity.json" | |
import { Link } from 'react-router-dom' |
This file contains hidden or 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
import React from "react"; | |
import Form from "./Form"; | |
import WeatherDiv from "./WeatherDiv"; | |
import "./Form.css" | |
import "./WeatherAPi.css" | |
import Slider from "react-slick" | |
import ActivityCards from "./ActivityCards" | |
import Activity from "./Activity.json" | |
import { Link } from 'react-router-dom' |
This file contains hidden or 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
func solutionA(_ A : [[Int]]) -> Int { | |
var saddlePoints = 0; | |
for i in 1..<A.count - 1 { | |
for j in 1..<A[i].count - 1 { | |
let columnTest = [A[i][j-1], A[i][j], A[i][j+1]].sorted {$0 < $1}; | |
let lignTest = [A[i-1][j], A[i][j], A[i+1][j]].sorted {$0 > $1}; | |
if (columnTest.first! == A[i][j] && lignTest.first! == A[i][j]) { | |
print("Got it One \(A[i][j]) \(i) \(j) \n"); | |
saddlePoints += 1 ; |