Run a workflow that executes other workflows in parallel.

## Explore further


For detailed documentation that includes this code sample, see the following:

- [Run a workflow that executes other workflows in parallel](https://docs.cloud.google.com/workflows/docs/tutorials/execute-workflows-from-workflow)
- [Use a Cloud Tasks queue to buffer your workflow executions](https://docs.cloud.google.com/workflows/docs/tutorials/buffer-workflows-executions)

## Code sample

### YAML

    main:
      params: [args]
      steps:
        - init:
            assign:
              - iteration : ${args.iteration}
        - wait:
            call: sys.sleep
            args:
                seconds: 10
        - check_iteration_even_or_odd:
            switch:
              - condition: ${iteration % 2 == 0}
                next: raise_error
        - return_message:
            return: ${"Hello world"+iteration}
        - raise_error:
            raise: ${"Error with iteration "+iteration}

## What's next


To search and filter code samples for other Google Cloud products, see the
[Google Cloud sample browser](https://docs.cloud.google.com/docs/samples?product=workflows).