Example #1
0
def f1(arg):
    ''' Функция ​f1​ должна вывести отсортированный список профессий
    без повторений (строки в разном регистре считать равными).
    Сортировка должна​ игнорировать регистр​. Используйте наработки
    из предыдущих заданий.'''
    #raise NotImplemented
    return sorted(unique(field(arg, 'job-name'), ignore_case=True))
Example #2
0
def f1Analog(args):
    JobsArray = []
    for i in args:
        for k, d in i.items():
            if k == "job-name":
                JobsArray.append(d)
    UJ = unique(JobsArray, True)
    UJA = []
    f = True
    while f:
        try:
            UJA.append(next(UJ))
        except StopIteration:
            f = False
    UJA = sorted(UJA)
    return (UJA)
Example #3
0
def f1(arg):
    # Отсортированный без повторений Список названий профессий
    return sorted((x for x in unique(list(field(data, "job-name")), ignore_case=True)))
Example #4
0
def f1(data):
    return sorted(list(unique(list(field(data, 'job-name')),
                              ignore_case=True)))
Example #5
0
def f1(arg):
    return sorted([j for j in unique((dict(i)['job-name'] for i in arg))])
Example #6
0
#!/usr/bin/env python3
from librip.gens import gen_random
from librip.gens import gen_random_one_string
from librip.iterators import unique

data1 = list(i
             for i in unique([1, 1, 1, 1, 1, 2, 2, 2, 2, 2], ignore_case=True))
data2 = list(i for i in unique(gen_random(1, 3, 10), ignore_case=True))

data4 = list(i for i in unique(['a', 'A', 'b', 'B'], ignore_case=True))
data5 = list(i for i in unique(['a', 'A', 'b', 'B'], ignore_case=False))
print(data1)
print(data2)
print(data4)
print(data5)
#Реализация задания 2
Example #7
0
def f1(arg):
    return sorted(unique([x for x in field(arg, "job-name")],
                         ignore_case=True),
                  key=str.lower)
Example #8
0
def f1(arg):
    return sorted(list(unique(field(arg, "job-name"), ignore_case=True)), key=lambda x: str.casefold(x))
Example #9
0
def f1(arg):
    return (sorted(
        [i for i in unique([j['job-name'] for j in arg], ignore_case=True)]))
Example #10
0
def f1(arg):
    return sorted(unique(field(arg[0], "job-name"), ignore_case=True))
Example #11
0
def f1(arg):
    return sorted(unique(field(data, "job-name"), ignore_case=True),
                  key=lambda x: x.lower())
Example #12
0
def f1(arg):
    return sorted(job for job in unique(field(arg, "job-name"), True))
Example #13
0
def f1(arg):
    return sorted(unique(field(arg, "job-name")))
Example #14
0
def f1(data):
    return sorted((unique(field(data, 'job-name'), ignore_case=False)),
                  key=lambda x: x.lower())
Example #15
0
def f1(arg):
    return list(
        sorted(unique(field(data, 'job-name'), ignore_case=True),
               key=lambda x: x.lower()))
Example #16
0
def f1(arg):
    return sorted(unique([x for x in field(arg, 'job-name')],
                         ignore_case=True))
Example #17
0
def f1(arg):
    return sorted((x for x in unique(list(field(data, "job-name")), True)))
Example #18
0
def f1(arg):
    return sorted(unique(field(arg, 'job-name'), ignore_case=True))
Example #19
0
def f1(arg):
    return sorted(unique(field(arg, 'job-name'), ignore_case=1),
                  key=lambda x: x.lower())
Example #20
0
File: ex_6.py Project: aksesss/lab4
def f1(arg):
    return sorted(unique((field(arg, 'job-name')), ignore_case=True),
                  key=str.lower)
Example #21
0
def f1(arg):
    return sorted(
        [a for a in unique([i["job-name"] for i in arg], ignore_case=1)])
Example #22
0
def f1(arg):
    uni = unique([i for i in field(arg, 'job-name')], ignore_case=True)
    for i in uni:
        pass
    return uni.items
Example #23
0
def f1(arg):
   #return (sorted(unique(field(arg,"job-name"),ignore_case=True)))
   return sorted(unique(field(arg, "job-name"), ignore_case=1), key=lambda x:x.lower())
Example #24
0
def f1(arg):
    return list(
        sorted(list(unique(list(field(arg, 'job-name')), ignore_case=True))))
Example #25
0
def f1(arg):
    job = list(field(arg, 'job-name'))
    job = unique(job, ignore_case = True)
    job = sorted(job)
    return job
Example #26
0
def f1(arg):

    return list(unique(arg))
Example #27
0
def f1(arg):
    return sorted(list(unique(field(arg, 'job-name'))),
                  key=lambda s: s.lower())
Example #28
0
def f1(arg):
    return list(unique(list(field(arg, "job-name")), ignore_case=True))
Example #29
0
File: ex_6.py Project: Eyphie/lab4
def f1(arg):
    return sorted(unique([i for i in field(arg, 'job-name')],
                         ignore_case=True),
                  key=lambda x: x.lower())
Example #30
0
def f1(arg):
    return list(unique(sorted(field(arg, "job-name"))))