Posts by SakuraFreak • 319 points
15 posts
-
2
votes1
answer79
viewsA: Python - update() failure to merge dictionaries
Come on, first you have to understand how a dictionary works. The dictionary has the following structure: Dicionário[Chave] = valor or can also be shown as follows: Dicionário = {Chave: valor} Keys…
-
0
votes2
answers330
viewsA: Web scraping of a microsoft form Forms returns None [python]
microsoft Forms has an undocumented REST(API) service. It is from this JSON request that information is digested. First let’s find out where GET comes from that will get the information.…
-
0
votes1
answer95
viewsA: Create column in dataframe that contains the list of row values except null values (Nan)
Be as simple as possible with the code. It will help you for both debugging and readability of the code, in case someone else needs to analyze. I recommend reading the pandas library, that there are…
-
0
votes1
answer5701
viewsA: Syntaxerror: Unexpected EOF while Parsing
As Giovanni said, we’re missing one try with except. Moreover, in this particular case, only one try: while a != 7: try: if len(codigo)!=len(nome) and len(nome)!=len(saldo): raise…
pythonanswered SakuraFreak 319 -
0
votes2
answers127
viewsA: Difficulty in identifying min value and sending selected Cells by email. VBA
You need to add the references you will use... In VBA, go to Tools>References... I recommend marking the following references: Visual Basic for Applications OLE Automation Microsoft Excel X.XX…
-
2
votes2
answers118
viewsA: Why does multiple variable assignment create a list when used with the asterisk operator?
I was reading the book I had quoted in the comments again, and I ended up jumping to the answer. Giving a deep search I ended up finding the discussion:…
-
0
votes1
answer46
viewsA: Use a class method from a concatenated string
When we program in object orientation, we use Getters and Setters to obtain values within a variable and encapsulation of the data.... I recommend studying object-oriented programming to understand…
-
1
votes1
answer222
viewsA: How to return a JSON with special characters in Flask?
The answer to the JSON file is perfectly ok! Special characters are encoded this way for compatibility and security reasons; because of html Escaping (which can bring vulnerabilities to the system)…
-
0
votes2
answers133
viewsA: How to create two y points for a same x?
Leafar’s answer is correct, but it will only work if you treat the data correctly. Treating data from a line-separated file texto = '''1;5 2;-2 3;4.5 4;10 5;6''' # Para cada linha que tiver na…
pythonanswered SakuraFreak 319 -
0
votes2
answers3082
viewsA: Python data entry with multiple lines
Abuse and use of try texto = '''1 teste 1.5 balb 512 1,4''' # Separa String por linhas e cria uma lista lst = texto.split('\n') lst_tratada = [] # Para cada valor que estiver na lista for i in lst:…
-
0
votes1
answer699
viewsA: Proxy error npm install
You need to create a system environment variable in order to use the internet via the Windows terminal. Start the terminal as admin and type: set HTTP_PROXY=http://usuario:senha@IP_ou_DNS:porta set…
-
3
votes2
answers64
viewsA: First Letters of the full name
Just use the property text-Transform of the CSS Directly in HTML <input style="text-transform:capitalize".... By a. css file tag{ text-transform:capitalize; }…
htmlanswered SakuraFreak 319 -
2
votes3
answers1161
viewsA: Hanoi Tower - How does this recursive solution work?
A good way to understand how recursive methods work is to understand its pattern. (It makes it much easier if you take the formula directly, but anyway) (Recursion is part of an exact module:…
-
0
votes2
answers388
viewsA: Calculate working cut-off date
This API only passes the holidays anyway? I think I could use this same API to know if it is weekend or not. But anyway..... Using the datetime library, you should first format the "date"…
-
2
votes1
answer805
viewsA: VBA Calling program in Python
I recommend these two methods Using the Library Shell method Retval: dim Retval executarScript = Shell("<localização do executável python.exe> " & "<localização do script>") Create a…