Skip to content

Instantly share code, notes, and snippets.

@nutszebra
Last active November 20, 2015 09:40
Show Gist options
  • Save nutszebra/500dd378eed35e3d9e9c to your computer and use it in GitHub Desktop.
Save nutszebra/500dd378eed35e3d9e9c to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#Link: http://www.cl.ecei.tohoku.ac.jp/nlp100/
"""
Question 01:
01. 「パタトクカシーー」
「パタトクカシーー」という文字列の1,3,5,7文字目を取り出して連結した文字列を得よ.
"""
word = u"パタトクカシーー"
print("".join([letter for letter, index in zip(word,range(0,len(a))) if index % 2 == 0]))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment