python-3.x

Connect Google Calendar to Telegram bot Python

I started learning how to create chatbots in telegram in Python using the pyTelegramBotAPI library. I want to create a bot th ... Starting new HTTPS connection (1): api.telegram.org Please provide an example of the code for the pyTelegramBotAPI library.

Make a round button in tkinter

Is it possible to make round buttons in tkinter and, if possible, how?

You need to put a timer on the Vkontakte bot. The bot is written in Python

I need to add a timer to the bot, so that the "TK" command can be executed 1 time in 30 minutes. Example: I) Tz Bot) here ... id, random_id=event.random_id, message='Я вас не понимаю.\nНапишите «ТЗ»' )

Translating code from pascal to python

There is code in pascal and you need to write code that also works in python: var a: array[1..10000] of integer; {исходные ... 1, N): if (a[i] * a[j] > maxvalue) and (a[i] * a[j] %14 == 0): maxvalue = a[i] * a[j] print(maxvalue)

Bold yellow text in the discord code block

I wanted to ask a question about discord. Fixed a screen from my bos, where you can see that the bot writes in yellow bold te ... e code block. I can't find anywhere how to do this and whether it can be done using the library discord.py or just on python

How to run GTA SAMP 0.3.7 server via Python?

I ran into a problem like this. I need to make it so that in the Python code it would be possible to start a separate SAMP server, without going to the SAMP client. Thank you so much for your help!

You need to display the sequence # and ' '

You need to display this figure: I solved it in python like this: for x in range(6): for y in range(x+1): if x == 0: ... z = ' ' elif x == 6: z = ' ' print('#', z, '#', sep='') Please tell me a less cumbersome solution

How to delete outdated libraries (packages)

In the folder \pkgs, many packages with previous versions have accumulated. For example, pandas-1.0.3, pandas-0.25.0, pandas- ... ble packages. The pkgs folder already takes up 25 GB. Is there any command to remove all outdated (old) versions of packages?

How to assign numeric keys to Numpad in keyPressEvent

I don't know the name of the key (if there is one).) def keyPressEvent(self, e): if e.key() == Qt.Key_NumPad1 #как отобразить нажатие клавиш NumPad'а?

How can I open a DLL file in Python

When writing a script, you need to open the DLL file and edit it in Python. Maybe there are special libraries that will allow you to open a DLL file and redachit it?

Python 3 Time Counting

The user enters the number of hours and minutes. All combinations are possible, i.e. it will enter only hours or only minutes ... hour = minute // a ps2_state.config(text=f"Оставшееся время: {minute} минут") second = second - 1 time.sleep(1)

How to make a regression neural network in Python?

How can I implement a regression neural network in Python? I recently started studying neural networks, and I ran into a prob ... t the direction of movement of the snake, for example, 0-to the left, 1-to the right. Accordingly, also for the Y coordinate.

How to determine the size of android screens on kivy

You can help. I need python Kivy to determine the length and height of the phone's display to adapt applications, since the proportions are known. Is there any way to do this?

How do I find the length of a circle in an image?

Given an image, you need to find the length of the circle on it, I tried to do this using opencv-python by coordinates , but ... h of this arc, please tell me how this can be done using built-in datasets, for example, something like finding the letter C.

How do I remove the distance between widgets in QHBoxLayout?

The horizontal container box1 contains the containers box2 and box3. box2 contains buttons with images, and box3 has a color, ... main__': import sys app = QtWidgets.QApplication(sys.argv) w = MyWindow() w.show() sys.exit(app.exec_())

Getting the color and direction of the arrow OpenCV python

Good afternoon, your help is required, you need to determine the color of the shape and the direction of the arrow from 0 to ... cv.drawContours(img, [box], -1, (255, 0, 0), 2) cv.imshow('contours', img) cv.waitKey() cv.destroyAllWindows()

How do I change the text color in QLabel?

There is QLabel, how do I change the text color in RGB? self.Label = QtWidgets.QLabel("", self) self.Label.move(50, 30) self.Label.resize(421, 41)

Spiral matrix from the center, python

Help make the matrix fillings spiral out of the center. I'm already confused about these indexes. Here are my attempts to do ... 3) print() At the moment, the output looks like this: 7 8 1 6 0 2 5 4 3 Where does it go wrong?

working with the QTabWidget class, placing tabs

There is a panel with tabs (there are only three), how to make tab number 3 on top like here: I would be very grateful Code: ... urrentIndex(0) vbox = QtWidgets.QVBoxLayout() vbox.addWidget(tab) window.setLayout(vbox) window.show() sys.exit(app.exec_())

How do I navigate to another directory on the command line using a Python script?

When I open the command prompt, I am in the root directory of my disk. How can I write such a script in Python, so that when ... .com/questions/1015886/Как-выполнить-команду-в-cmd-через-python) I applied, but I didn't find an answer to my question there.