Загружаю черновик ДЗ по поиску второго символа в строке
This commit is contained in:
parent
8db71662f0
commit
ac65502e7e
|
@ -0,0 +1,3 @@
|
||||||
|
# Default ignored files
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
|
@ -0,0 +1,6 @@
|
||||||
|
<component name="InspectionProjectProfileManager">
|
||||||
|
<settings>
|
||||||
|
<option name="USE_PROJECT_PROFILE" value="false" />
|
||||||
|
<version value="1.0" />
|
||||||
|
</settings>
|
||||||
|
</component>
|
|
@ -0,0 +1,4 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.11 (ДЗ тестирование 2)" project-jdk-type="Python SDK" />
|
||||||
|
</project>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/.idea/ДЗ тестирование 2.iml" filepath="$PROJECT_DIR$/.idea/ДЗ тестирование 2.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,6 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="$PROJECT_DIR$/../../.." vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="PYTHON_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager">
|
||||||
|
<content url="file://$MODULE_DIR$" />
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
</component>
|
||||||
|
</module>
|
|
@ -0,0 +1,17 @@
|
||||||
|
def first_recurring_char(s):
|
||||||
|
array = []
|
||||||
|
z = str
|
||||||
|
if type(s) is str and s is not None:
|
||||||
|
for i in s:
|
||||||
|
array.append(i)
|
||||||
|
k = + 1
|
||||||
|
for j in array[0:k - 1]:
|
||||||
|
if j == i:
|
||||||
|
p = +1
|
||||||
|
print(p)
|
||||||
|
if p > 1:
|
||||||
|
z = str(j)
|
||||||
|
return z
|
||||||
|
|
||||||
|
|
||||||
|
print(first_recurring_char("вадвава"))
|
Loading…
Reference in New Issue