Interesting questions
-
0
votes2
answers195
viewsHow to remove class from other elements by clicking the button?
There are several buttons, which when clicking, opens a box with options. How do I so that when I open a box, the others close? var button = document.querySelectorAll(".popup-btn") var pop =…
-
3
votes1
answer493
viewsFinding out which value is higher
Follow the code below: <?php $timeZone = new DateTimeZone('UTC'); $dataInicio = new DateTime('2016-06-14', $timeZone);//dataFinal do evento $dataFinal = new DateTime('2016-06-25',…
-
1
votes1
answer291
viewsEndlessly map
I’m developing a game and I just found a difficulty somewhat boring, it’s a logic problem... Next: Imagine the scene of the game Where, the black square in which the "Player" is, is the camera view…
-
-3
votes1
answer203
viewsChange php variable value through media queries
I need to change the variable value of a function according to the screen resolution (when reducing the screen the value has to be updated immediately). You can change this value through CSS media…
-
1
votes1
answer900
viewsHow to set a session timeout on the web.config
People I need a timeout for my web.config that if the user is not tinkering with the system it expires, if he is tinkering with the system does not expire time. It’s possible to have something like…
-
0
votes3
answers119
viewsHow do I reset the Flask server using if within the algorithm?
Next, I am creating a game in order to learn, however, I need this game to "reset" when the amount of attempts is reached. At the beginning of the code I have the following: from random import…
-
1
votes3
answers118
viewsCSS or JS selector
I have a paragraph with no id that I need to style. Styling can only occur for this paragraph. Example: <p>Conteúdo</p> So I want to apply CSS only to it. seletor {estilo;} Note: I…
-
1
votes2
answers74
viewsVector that generates elements
I would like to generate a vector where your next position element is added to 1. For example: be a vetor[3], would like that v[0] = 1 and v[1] = v[0] + 1, v[2] = v[1] + 1 and so on. How would you…
-
3
votes3
answers3895
viewsPython date validation (tests)
I am trying to do a date validation with Python. My exercise asks for the validation of months with 31 days and leap year. def data_valida(data): #Valida data. Recebe uma string no formato…
-
1
votes1
answer113
viewsRelation between structs in C
I have the following scenario: typedef struct Unidade{ int cod; } und; typedef struct Produto{ int cod; char nome[100]; und unidade; } prod; As you can see I have a unit type variable inside the…
-
0
votes0
answers1885
viewsHow to hide top bar (title and logo) from Youtube iframe
After the Youtube API Update in September, the "showinfo=0" command stopped working in iframes. Is there any way to hide this bar from the top (Title, logo, share and view option later)? Another…
-
-1
votes4
answers60
viewsAveraging
I am trying to make an average calculation between 2 values, but at the time of printing it is printing wrong, in what I am missing? var p1 = Number ('7.0') var p2 = Number ('9.3') const media = 2 /…
javascriptasked 7 years, 11 months ago Miyuki Fukagawa 29 -
1
votes1
answer361
viewsCatch the return of a Alertdialog to treat willpopscope
I have a function called showAlertDialogSimNao() and this receives the name parameter and content. I would like to take the return of this function and treat at the end of the application. However…
-
0
votes0
answers31
viewsFirebase: Rename events
I received from my company the work of implementing Firebase in our flutter app, studied firebase and found the Events page of Firebase Analytics, and saw that the events already "came with…
-
2
votes1
answer186
viewsChange specific string fields in Javascript
I have the following string: string = "Este aqui é o valor do cliente 000.000.00 01"; I need to create a function, that "Search" inside that string that contains letters and numbers if there is a…
javascriptasked 12 years, 4 months ago user7605 1,679 -
3
votes3
answers2128
viewsSend PHP variable to Shell Script
I have a file .sh and it has variables that I need to receive from PHP, follow an example: //variavel 1 que preciso receber externamente NAME="" //variavel 2 que preciso receber externamente DIR=""…
-
3
votes0
answers111
viewsMongodb stopping to work
We are in the company testing a project using Mongodb database. The database is installed on a Linux server (Centos), with 32GB of RAM, but sometimes the database para de funcionar and needs to be…
-
3
votes1
answer77
viewsIs there an alternative in Javascript similar to Java 8’s "flatMap"?
I need to do an element mapping that returns a vector to me. However, I am already doing a job on top of a array, then the simple map will return me a vector containing vectors. In this case, I have…
javascriptasked 8 years, 1 month ago Jefferson Quesado 22,370 -
0
votes2
answers364
viewssql inserts the wrong datetime into the table
i to using microsoft sql manager,and was trying to insert a date in my table,the problem is that it is entering the wrong date,i do the following command for the manager table INSERT INTO tblCliente…
-
15
votes2
answers6108
viewsRandom draw, but with different odds
I am implementing a system where the user clicks on a button and a draw with balls of different colors occurs, but for each color there is a probability: He has a 30% chance of catching a blue ball…