Posts by arksdf • 85 points
5 posts
-
0
votes2
answers81
viewsQ: Nodejs - Change the value of a vector in an if Else
I’m trying to make a function that can return the values if they’re being passed by the parameters or by the body of a request, the solution I thought was this: function getReqInfo(req){ let params…
-
2
votes1
answer84
viewsQ: Is there a problem using objects like this in Node.js?
I’m working on a system that contains a simple CRUD for tables from a Postgres database, in which new tables can be added eventually. So to avoid rewriting the controllers all the time, I did the…
-
4
votes3
answers2117
viewsQ: Regular expression to return text between keys
I have this String: str = "Eu sou uma string {dentro de uma string {dentro de outra} }" What regular expression can I use to get just: dentro de uma string {dentro de outra}…
-
1
votes1
answer666
viewsA: Point of Intersection between two lines using Geoplades
Try this function: def exists_intersection(line1, line2): def ccw(A,B,C): return (C[1]-A[1])*(B[0]-A[0]) > (B[1]-A[1])*(C[0]-A[0]) def intersect(line1, line2): A,B = line1 C,D = line2 bol1 =…
-
1
votes1
answer973
views