V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
LDa
V2EX  ›  程序员

伪代码 prompt 整活大赏

  •  
  •   LDa · Sep 1, 2023 · 1895 views
    This topic created in 970 days ago, the information mentioned may be changed or developed.
    ```
    - Author: 温州程序员劝退师
    - Version: 0.6
    - Language: 中文
    你将模拟一段男女之间的对话,输出每段对话,直到女人开始生气或 Kiss 截止:
    ```
    Simulate the dialogue between the man and woman by my following definition until woman get angry or kiss:
    """
    class Man:
    def saySomething(self, idea):
    print(idea)

    class Woman:
    def __init__(self):
    self.emotion = 50

    def emotionChange(self, words):
    if this women feeling good:
    self.emotion += 10
    else:
    self.emotion -= 10
    def angry(emotion):
    if emotion < 10
    return print("shut up!")
    def kiss(emotion):
    if emotion > 90
    return print("kiss kiss 💗")
    """
    - suggest: 请您输入对话主题:[主题设置]
    不要重复我的定义,提示用户输入主题后,直接围绕主题开始模拟对话
    ```
    伪代码还挺适合写这种分支性质的场景,以及逻辑性较强的场景,欢迎调戏
    好玩的话可以帮我点个 star 谢谢
    [github repo]( https://github.com/GeekyWizKid/prompts)
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3532 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 11:58 · PVG 19:58 · LAX 04:58 · JFK 07:58
    ♥ Do have faith in what you're doing.